home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 2000 July: Mac OS SDK / Dev.CD Jul 00 SDK2.toast / Development Kits / Cross Platform / QuickTime 4.1.2 Windows SDK / CIncludes / ImageCompression.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-04-12  |  103.7 KB  |  2,593 lines  |  [TEXT/R*ch]

  1. /*
  2.      File:        ImageCompression.h
  3.  
  4.      Contains:    QuickTime interfaces
  5.  
  6.      Version:    Technology:    
  7.                  Release:    QuickTime 4.1
  8.  
  9.      Copyright:    (c) 1990-1999 by Apple Computer, Inc., all rights reserved
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. */
  17. #ifndef __IMAGECOMPRESSION__
  18. #define __IMAGECOMPRESSION__
  19.  
  20. #ifndef __MACTYPES__
  21.     #include <MacTypes.h>
  22. #endif
  23.  
  24. #ifndef __QUICKDRAW__
  25.     #include <Quickdraw.h>
  26. #endif
  27.  
  28. #ifndef __QDOFFSCREEN__
  29.     #include <QDOffscreen.h>
  30. #endif
  31.  
  32. #ifndef __COMPONENTS__
  33.     #include <Components.h>
  34. #endif
  35.  
  36. #ifndef __STANDARDFILE__
  37.     #include <StandardFile.h>
  38. #endif
  39.  
  40.  
  41.  
  42.  
  43. #if PRAGMA_ONCE
  44. #pragma once
  45. #endif
  46.  
  47. #ifdef __cplusplus
  48. extern "C" {
  49. #endif
  50.  
  51. #if PRAGMA_IMPORT
  52. #pragma import on
  53. #endif
  54.  
  55. #if PRAGMA_STRUCT_ALIGN
  56.     #pragma options align=mac68k
  57. #elif PRAGMA_STRUCT_PACKPUSH
  58.     #pragma pack(push, 2)
  59. #elif PRAGMA_STRUCT_PACK
  60.     #pragma pack(2)
  61. #endif
  62.  
  63.  
  64. struct MatrixRecord {
  65.     Fixed                             matrix[3][3];
  66. };
  67. typedef struct MatrixRecord                MatrixRecord;
  68. typedef MatrixRecord *                    MatrixRecordPtr;
  69. enum {
  70.     kRawCodecType                = FOUR_CHAR_CODE('raw '),
  71.     kCinepakCodecType            = FOUR_CHAR_CODE('cvid'),
  72.     kGraphicsCodecType            = FOUR_CHAR_CODE('smc '),
  73.     kAnimationCodecType            = FOUR_CHAR_CODE('rle '),
  74.     kVideoCodecType                = FOUR_CHAR_CODE('rpza'),
  75.     kComponentVideoCodecType    = FOUR_CHAR_CODE('yuv2'),
  76.     kJPEGCodecType                = FOUR_CHAR_CODE('jpeg'),
  77.     kMotionJPEGACodecType        = FOUR_CHAR_CODE('mjpa'),
  78.     kMotionJPEGBCodecType        = FOUR_CHAR_CODE('mjpb'),
  79.     kSGICodecType                = FOUR_CHAR_CODE('.SGI'),
  80.     kPlanarRGBCodecType            = FOUR_CHAR_CODE('8BPS'),
  81.     kMacPaintCodecType            = FOUR_CHAR_CODE('PNTG'),
  82.     kGIFCodecType                = FOUR_CHAR_CODE('gif '),
  83.     kPhotoCDCodecType            = FOUR_CHAR_CODE('kpcd'),
  84.     kQuickDrawGXCodecType        = FOUR_CHAR_CODE('qdgx'),
  85.     kAVRJPEGCodecType            = FOUR_CHAR_CODE('avr '),
  86.     kOpenDMLJPEGCodecType        = FOUR_CHAR_CODE('dmb1'),
  87.     kBMPCodecType                = FOUR_CHAR_CODE('WRLE'),
  88.     kWindowsRawCodecType        = FOUR_CHAR_CODE('WRAW'),
  89.     kVectorCodecType            = FOUR_CHAR_CODE('path'),
  90.     kQuickDrawCodecType            = FOUR_CHAR_CODE('qdrw'),
  91.     kWaterRippleCodecType        = FOUR_CHAR_CODE('ripl'),
  92.     kFireCodecType                = FOUR_CHAR_CODE('fire'),
  93.     kCloudCodecType                = FOUR_CHAR_CODE('clou'),
  94.     kH261CodecType                = FOUR_CHAR_CODE('h261'),
  95.     kH263CodecType                = FOUR_CHAR_CODE('h263'),
  96.     kDVCNTSCCodecType            = FOUR_CHAR_CODE('dvc '),
  97.     kDVCPALCodecType            = FOUR_CHAR_CODE('dvcp'),
  98.     kDVCProNTSCCodecType        = FOUR_CHAR_CODE('dvpn'),
  99.     kDVCProPALCodecType            = FOUR_CHAR_CODE('dvpp'),
  100.     kBaseCodecType                = FOUR_CHAR_CODE('base'),
  101.     kFLCCodecType                = FOUR_CHAR_CODE('flic'),
  102.     kTargaCodecType                = FOUR_CHAR_CODE('tga '),
  103.     kPNGCodecType                = FOUR_CHAR_CODE('png '),
  104.     kTIFFCodecType                = FOUR_CHAR_CODE('tiff'),        /*    NOTE: despite what might seem obvious from the two constants*/
  105.                                                                 /*    below and their names, they really are correct. 'yuvu' really */
  106.                                                                 /*    does mean signed, and 'yuvs' really does mean unsigned. Really. */
  107.     kComponentVideoSigned        = FOUR_CHAR_CODE('yuvu'),
  108.     kComponentVideoUnsigned        = FOUR_CHAR_CODE('yuvs'),
  109.     kCMYKCodecType                = FOUR_CHAR_CODE('cmyk'),
  110.     kMicrosoftVideo1CodecType    = FOUR_CHAR_CODE('msvc'),
  111.     kSorensonCodecType            = FOUR_CHAR_CODE('SVQ1'),
  112.     kIndeo4CodecType            = FOUR_CHAR_CODE('IV41'),
  113.     k64ARGBCodecType            = FOUR_CHAR_CODE('b64a'),
  114.     k48RGBCodecType                = FOUR_CHAR_CODE('b48r'),
  115.     k32AlphaGrayCodecType        = FOUR_CHAR_CODE('b32a'),
  116.     k16GrayCodecType            = FOUR_CHAR_CODE('b16g'),
  117.     kMpegYUV420CodecType        = FOUR_CHAR_CODE('myuv'),
  118.     kYUV420CodecType            = FOUR_CHAR_CODE('y420'),
  119.     kSorensonYUV9CodecType        = FOUR_CHAR_CODE('syv9'),
  120.     k422YpCbCr8CodecType        = FOUR_CHAR_CODE('2vuy'),        /* Component Y'CbCr 8-bit 4:2:2  */
  121.     k444YpCbCr8CodecType        = FOUR_CHAR_CODE('v308'),        /* Component Y'CbCr 8-bit 4:4:4  */
  122.     k4444YpCbCrA8CodecType        = FOUR_CHAR_CODE('v408'),        /* Component Y'CbCrA 8-bit 4:4:4:4 */
  123.     k422YpCbCr16CodecType        = FOUR_CHAR_CODE('v216'),        /* Component Y'CbCr 10,12,14,16-bit 4:2:2*/
  124.     k422YpCbCr10CodecType        = FOUR_CHAR_CODE('v210'),        /* Component Y'CbCr 10-bit 4:2:2 */
  125.     k444YpCbCr10CodecType        = FOUR_CHAR_CODE('v410'),        /* Component Y'CbCr 10-bit 4:4:4 */
  126.     k4444YpCbCrA8RCodecType        = FOUR_CHAR_CODE('r408')        /* Component Y'CbCrA 8-bit 4:4:4:4, rendering format. full range alpha, zero biased yuv*/
  127. };
  128.  
  129.  
  130. /* one source effects */
  131. enum {
  132.     kBlurImageFilterType        = FOUR_CHAR_CODE('blur'),
  133.     kSharpenImageFilterType        = FOUR_CHAR_CODE('shrp'),
  134.     kEdgeDetectImageFilterType    = FOUR_CHAR_CODE('edge'),
  135.     kEmbossImageFilterType        = FOUR_CHAR_CODE('embs'),
  136.     kConvolveImageFilterType    = FOUR_CHAR_CODE('genk'),
  137.     kAlphaGainImageFilterType    = FOUR_CHAR_CODE('gain'),
  138.     kRGBColorBalanceImageFilterType = FOUR_CHAR_CODE('rgbb'),
  139.     kHSLColorBalanceImageFilterType = FOUR_CHAR_CODE('hslb'),
  140.     kColorSyncImageFilterType    = FOUR_CHAR_CODE('sync'),
  141.     kFilmNoiseImageFilterType    = FOUR_CHAR_CODE('fmns'),
  142.     kSolarizeImageFilterType    = FOUR_CHAR_CODE('solr'),
  143.     kColorTintImageFilterType    = FOUR_CHAR_CODE('tint'),
  144.     kLensFlareImageFilterType    = FOUR_CHAR_CODE('lens'),
  145.     kBrightnessContrastImageFilterType = FOUR_CHAR_CODE('brco')
  146. };
  147.  
  148. /* two source effects */
  149. enum {
  150.     kAlphaCompositorTransitionType = FOUR_CHAR_CODE('blnd'),
  151.     kCrossFadeTransitionType    = FOUR_CHAR_CODE('dslv'),
  152.     kChromaKeyTransitionType    = FOUR_CHAR_CODE('ckey'),
  153.     kImplodeTransitionType        = FOUR_CHAR_CODE('mplo'),
  154.     kExplodeTransitionType        = FOUR_CHAR_CODE('xplo'),
  155.     kGradientTransitionType        = FOUR_CHAR_CODE('matt'),
  156.     kPushTransitionType            = FOUR_CHAR_CODE('push'),
  157.     kSlideTransitionType        = FOUR_CHAR_CODE('slid'),
  158.     kWipeTransitionType            = FOUR_CHAR_CODE('smpt'),
  159.     kIrisTransitionType            = FOUR_CHAR_CODE('smp2'),
  160.     kRadialTransitionType        = FOUR_CHAR_CODE('smp3'),
  161.     kMatrixTransitionType        = FOUR_CHAR_CODE('smp4'),
  162.     kZoomTransitionType            = FOUR_CHAR_CODE('zoom')
  163. };
  164.  
  165. /* These are the bits that are set in the Component flags, and also in the codecInfo struct. */
  166. enum {
  167.     codecInfoDoes1                = (1L << 0),                    /* codec can work with 1-bit pixels */
  168.     codecInfoDoes2                = (1L << 1),                    /* codec can work with 2-bit pixels */
  169.     codecInfoDoes4                = (1L << 2),                    /* codec can work with 4-bit pixels */
  170.     codecInfoDoes8                = (1L << 3),                    /* codec can work with 8-bit pixels */
  171.     codecInfoDoes16                = (1L << 4),                    /* codec can work with 16-bit pixels */
  172.     codecInfoDoes32                = (1L << 5),                    /* codec can work with 32-bit pixels */
  173.     codecInfoDoesDither            = (1L << 6),                    /* codec can do ditherMode */
  174.     codecInfoDoesStretch        = (1L << 7),                    /* codec can stretch to arbitrary sizes */
  175.     codecInfoDoesShrink            = (1L << 8),                    /* codec can shrink to arbitrary sizes */
  176.     codecInfoDoesMask            = (1L << 9),                    /* codec can mask to clipping regions */
  177.     codecInfoDoesTemporal        = (1L << 10),                    /* codec can handle temporal redundancy */
  178.     codecInfoDoesDouble            = (1L << 11),                    /* codec can stretch to double size exactly */
  179.     codecInfoDoesQuad            = (1L << 12),                    /* codec can stretch to quadruple size exactly */
  180.     codecInfoDoesHalf            = (1L << 13),                    /* codec can shrink to half size */
  181.     codecInfoDoesQuarter        = (1L << 14),                    /* codec can shrink to quarter size */
  182.     codecInfoDoesRotate            = (1L << 15),                    /* codec can rotate on decompress */
  183.     codecInfoDoesHorizFlip        = (1L << 16),                    /* codec can flip horizontally on decompress */
  184.     codecInfoDoesVertFlip        = (1L << 17),                    /* codec can flip vertically on decompress */
  185.     codecInfoHasEffectParameterList = (1L << 18),                /* codec implements get effects parameter list call, once was codecInfoDoesSkew */
  186.     codecInfoDoesBlend            = (1L << 19),                    /* codec can blend on decompress */
  187.     codecInfoDoesWarp            = (1L << 20),                    /* codec can warp arbitrarily on decompress */
  188.     codecInfoDoesRecompress        = (1L << 21),                    /* codec can recompress image without accumulating errors */
  189.     codecInfoDoesSpool            = (1L << 22),                    /* codec can spool image data */
  190.     codecInfoDoesRateConstrain    = (1L << 23)                    /* codec can data rate constrain */
  191. };
  192.  
  193.  
  194. enum {
  195.     codecInfoDepth1                = (1L << 0),                    /* compressed data at 1 bpp depth available */
  196.     codecInfoDepth2                = (1L << 1),                    /* compressed data at 2 bpp depth available */
  197.     codecInfoDepth4                = (1L << 2),                    /* compressed data at 4 bpp depth available */
  198.     codecInfoDepth8                = (1L << 3),                    /* compressed data at 8 bpp depth available */
  199.     codecInfoDepth16            = (1L << 4),                    /* compressed data at 16 bpp depth available */
  200.     codecInfoDepth32            = (1L << 5),                    /* compressed data at 32 bpp depth available */
  201.     codecInfoDepth24            = (1L << 6),                    /* compressed data at 24 bpp depth available */
  202.     codecInfoDepth33            = (1L << 7),                    /* compressed data at 1 bpp monochrome depth  available */
  203.     codecInfoDepth34            = (1L << 8),                    /* compressed data at 2 bpp grayscale depth available */
  204.     codecInfoDepth36            = (1L << 9),                    /* compressed data at 4 bpp grayscale depth available */
  205.     codecInfoDepth40            = (1L << 10),                    /* compressed data at 8 bpp grayscale depth available */
  206.     codecInfoStoresClut            = (1L << 11),                    /* compressed data can have custom cluts */
  207.     codecInfoDoesLossless        = (1L << 12),                    /* compressed data can be stored in lossless format */
  208.     codecInfoSequenceSensitive    = (1L << 13)                    /* compressed data is sensitive to out of sequence decoding */
  209. };
  210.  
  211.  
  212. /* input sequence flags*/
  213. enum {
  214.     codecFlagUseImageBuffer        = (1L << 0),                    /* decompress*/
  215.     codecFlagUseScreenBuffer    = (1L << 1),                    /* decompress*/
  216.     codecFlagUpdatePrevious        = (1L << 2),                    /* compress*/
  217.     codecFlagNoScreenUpdate        = (1L << 3),                    /* decompress*/
  218.     codecFlagWasCompressed        = (1L << 4),                    /* compress*/
  219.     codecFlagDontOffscreen        = (1L << 5),                    /* decompress*/
  220.     codecFlagUpdatePreviousComp    = (1L << 6),                    /* compress*/
  221.     codecFlagForceKeyFrame        = (1L << 7),                    /* compress*/
  222.     codecFlagOnlyScreenUpdate    = (1L << 8),                    /* decompress*/
  223.     codecFlagLiveGrab            = (1L << 9),                    /* compress*/
  224.     codecFlagDiffFrame            = (1L << 9),                    /* decompress*/
  225.     codecFlagDontUseNewImageBuffer = (1L << 10),                /* decompress*/
  226.     codecFlagInterlaceUpdate    = (1L << 11),                    /* decompress*/
  227.     codecFlagCatchUpDiff        = (1L << 12),                    /* decompress*/
  228.     codecFlagSupportDisable        = (1L << 13),                    /* decompress*/
  229.     codecFlagReenable            = (1L << 14)                    /* decompress*/
  230. };
  231.  
  232. /* output sequence flags*/
  233. enum {
  234.     codecFlagOutUpdateOnNextIdle = (1L << 9),
  235.     codecFlagOutUpdateOnDataSourceChange = (1L << 10),
  236.     codecFlagSequenceSensitive    = (1L << 11),
  237.     codecFlagOutUpdateOnTimeChange = (1L << 12),
  238.     codecFlagImageBufferNotSourceImage = (1L << 13),
  239.     codecFlagUsedNewImageBuffer    = (1L << 14),
  240.     codecFlagUsedImageBuffer    = (1L << 15)
  241. };
  242.  
  243.  
  244.  
  245.  
  246. enum {
  247.                                                                 /* The minimum data size for spooling in or out data */
  248.     codecMinimumDataSize        = 32768L
  249. };
  250.  
  251.  
  252.  
  253. enum {
  254.     compressorComponentType        = FOUR_CHAR_CODE('imco'),        /* the type for "Components" which compress images */
  255.     decompressorComponentType    = FOUR_CHAR_CODE('imdc')        /* the type for "Components" which decompress images */
  256. };
  257.  
  258.  
  259. typedef Component                         CompressorComponent;
  260. typedef Component                         DecompressorComponent;
  261. typedef Component                         CodecComponent;
  262. #define    anyCodec                ((CodecComponent)0)
  263. #define    bestSpeedCodec            ((CodecComponent)-1)
  264. #define    bestFidelityCodec        ((CodecComponent)-2)
  265. #define    bestCompressionCodec    ((CodecComponent)-3)
  266. typedef OSType                             CodecType;
  267. typedef unsigned short                     CodecFlags;
  268. typedef unsigned long                     CodecQ;
  269. enum {
  270.     codecLosslessQuality        = 0x00000400,
  271.     codecMaxQuality                = 0x000003FF,
  272.     codecMinQuality                = 0x00000000,
  273.     codecLowQuality                = 0x00000100,
  274.     codecNormalQuality            = 0x00000200,
  275.     codecHighQuality            = 0x00000300
  276. };
  277.  
  278. enum {
  279.     codecLockBitsShieldCursor    = (1 << 0)                        /* shield cursor */
  280. };
  281.  
  282. enum {
  283.     codecCompletionSource        = (1 << 0),                        /* asynchronous codec is done with source data */
  284.     codecCompletionDest            = (1 << 1),                        /* asynchronous codec is done with destination data */
  285.     codecCompletionDontUnshield    = (1 << 2),                        /* on dest complete don't unshield cursor */
  286.     codecCompletionWentOffscreen = (1 << 3),                    /* codec used offscreen buffer */
  287.     codecCompletionUnlockBits    = (1 << 4),                        /* on dest complete, call ICMSequenceUnlockBits */
  288.     codecCompletionForceChainFlush = (1 << 5),                    /* ICM needs to flush the whole chain */
  289.     codecCompletionDropped        = (1 << 6)                        /* codec decided to drop this frame */
  290. };
  291.  
  292. enum {
  293.     codecProgressOpen            = 0,
  294.     codecProgressUpdatePercent    = 1,
  295.     codecProgressClose            = 2
  296. };
  297.  
  298. typedef CALLBACK_API( OSErr , ICMDataProcPtr )(Ptr *dataP, long bytesNeeded, long refcon);
  299. typedef CALLBACK_API( OSErr , ICMFlushProcPtr )(Ptr data, long bytesAdded, long refcon);
  300. typedef CALLBACK_API( void , ICMCompletionProcPtr )(OSErr result, short flags, long refcon);
  301. typedef CALLBACK_API( OSErr , ICMProgressProcPtr )(short message, Fixed completeness, long refcon);
  302. typedef CALLBACK_API( void , StdPixProcPtr )(PixMap *src, Rect *srcRect, MatrixRecord *matrix, short mode, RgnHandle mask, PixMap *matte, Rect *matteRect, short flags);
  303. typedef CALLBACK_API( void , QDPixProcPtr )(PixMap *src, Rect *srcRect, MatrixRecord *matrix, short mode, RgnHandle mask, PixMap *matte, Rect *matteRect, short flags);
  304. typedef CALLBACK_API( void , ICMAlignmentProcPtr )(Rect *rp, long refcon);
  305. typedef CALLBACK_API( void , ICMCursorShieldedProcPtr )(const Rect *r, void *refcon, long flags);
  306. typedef CALLBACK_API( void , ICMMemoryDisposedProcPtr )(Ptr memoryBlock, void *refcon);
  307. typedef void *                            ICMCursorNotify;
  308. typedef CALLBACK_API( OSErr , ICMConvertDataFormatProcPtr )(void *refCon, long flags, Handle desiredFormat, Handle sourceDataFormat, void *srcData, long srcDataSize, void **dstData, long *dstDataSize);
  309. typedef STACK_UPP_TYPE(ICMDataProcPtr)                             ICMDataUPP;
  310. typedef STACK_UPP_TYPE(ICMFlushProcPtr)                         ICMFlushUPP;
  311. typedef STACK_UPP_TYPE(ICMCompletionProcPtr)                     ICMCompletionUPP;
  312. typedef STACK_UPP_TYPE(ICMProgressProcPtr)                         ICMProgressUPP;
  313. typedef STACK_UPP_TYPE(StdPixProcPtr)                             StdPixUPP;
  314. typedef STACK_UPP_TYPE(QDPixProcPtr)                             QDPixUPP;
  315. typedef STACK_UPP_TYPE(ICMAlignmentProcPtr)                     ICMAlignmentUPP;
  316. typedef STACK_UPP_TYPE(ICMCursorShieldedProcPtr)                 ICMCursorShieldedUPP;
  317. typedef STACK_UPP_TYPE(ICMMemoryDisposedProcPtr)                 ICMMemoryDisposedUPP;
  318. typedef STACK_UPP_TYPE(ICMConvertDataFormatProcPtr)             ICMConvertDataFormatUPP;
  319. typedef long                             ImageSequence;
  320. typedef long                             ImageSequenceDataSource;
  321. typedef long                             ImageTranscodeSequence;
  322. typedef long                             ImageFieldSequence;
  323.  
  324. struct ICMProgressProcRecord {
  325.     ICMProgressUPP                     progressProc;
  326.     long                             progressRefCon;
  327. };
  328. typedef struct ICMProgressProcRecord    ICMProgressProcRecord;
  329. typedef ICMProgressProcRecord *            ICMProgressProcRecordPtr;
  330.  
  331. struct ICMCompletionProcRecord {
  332.     ICMCompletionUPP                 completionProc;
  333.     long                             completionRefCon;
  334. };
  335. typedef struct ICMCompletionProcRecord    ICMCompletionProcRecord;
  336. typedef ICMCompletionProcRecord *        ICMCompletionProcRecordPtr;
  337.  
  338. struct ICMDataProcRecord {
  339.     ICMDataUPP                         dataProc;
  340.     long                             dataRefCon;
  341. };
  342. typedef struct ICMDataProcRecord        ICMDataProcRecord;
  343. typedef ICMDataProcRecord *                ICMDataProcRecordPtr;
  344.  
  345. struct ICMFlushProcRecord {
  346.     ICMFlushUPP                     flushProc;
  347.     long                             flushRefCon;
  348. };
  349. typedef struct ICMFlushProcRecord        ICMFlushProcRecord;
  350. typedef ICMFlushProcRecord *            ICMFlushProcRecordPtr;
  351.  
  352. struct ICMAlignmentProcRecord {
  353.     ICMAlignmentUPP                 alignmentProc;
  354.     long                             alignmentRefCon;
  355. };
  356. typedef struct ICMAlignmentProcRecord    ICMAlignmentProcRecord;
  357. typedef ICMAlignmentProcRecord *        ICMAlignmentProcRecordPtr;
  358.  
  359. struct DataRateParams {
  360.     long                             dataRate;
  361.     long                             dataOverrun;
  362.     long                             frameDuration;
  363.     long                             keyFrameRate;
  364.     CodecQ                             minSpatialQuality;
  365.     CodecQ                             minTemporalQuality;
  366. };
  367. typedef struct DataRateParams            DataRateParams;
  368. typedef DataRateParams *                DataRateParamsPtr;
  369.  
  370. struct ImageDescription {
  371.     long                             idSize;                        /* total size of ImageDescription including extra data ( CLUTs and other per sequence data ) */
  372.     CodecType                         cType;                        /* what kind of codec compressed this data */
  373.     long                             resvd1;                        /* reserved for Apple use */
  374.     short                             resvd2;                        /* reserved for Apple use */
  375.     short                             dataRefIndex;                /* set to zero  */
  376.     short                             version;                    /* which version is this data */
  377.     short                             revisionLevel;                /* what version of that codec did this */
  378.     long                             vendor;                        /* whose  codec compressed this data */
  379.     CodecQ                             temporalQuality;            /* what was the temporal quality factor  */
  380.     CodecQ                             spatialQuality;                /* what was the spatial quality factor */
  381.     short                             width;                        /* how many pixels wide is this data */
  382.     short                             height;                        /* how many pixels high is this data */
  383.     Fixed                             hRes;                        /* horizontal resolution */
  384.     Fixed                             vRes;                        /* vertical resolution */
  385.     long                             dataSize;                    /* if known, the size of data for this image descriptor */
  386.     short                             frameCount;                    /* number of frames this description applies to */
  387.     Str31                             name;                        /* name of codec ( in case not installed )  */
  388.     short                             depth;                        /* what depth is this data (1-32) or ( 33-40 grayscale ) */
  389.     short                             clutID;                        /* clut id or if 0 clut follows  or -1 if no clut */
  390. };
  391. typedef struct ImageDescription            ImageDescription;
  392. typedef ImageDescription *                ImageDescriptionPtr;
  393. typedef ImageDescriptionPtr *            ImageDescriptionHandle;
  394.  
  395. struct CodecInfo {
  396.     Str31                             typeName;                    /* name of the codec type i.e.: 'Apple Image Compression' */
  397.     short                             version;                    /* version of the codec data that this codec knows about */
  398.     short                             revisionLevel;                /* revision level of this codec i.e: 0x00010001 (1.0.1) */
  399.     long                             vendor;                        /* Maker of this codec i.e: 'appl' */
  400.     long                             decompressFlags;            /* codecInfo flags for decompression capabilities */
  401.     long                             compressFlags;                /* codecInfo flags for compression capabilities */
  402.     long                             formatFlags;                /* codecInfo flags for compression format details */
  403.     UInt8                             compressionAccuracy;        /* measure (1-255) of accuracy of this codec for compress (0 if unknown) */
  404.     UInt8                             decompressionAccuracy;        /* measure (1-255) of accuracy of this codec for decompress (0 if unknown) */
  405.     unsigned short                     compressionSpeed;            /* ( millisecs for compressing 320x240 on base mac II) (0 if unknown)  */
  406.     unsigned short                     decompressionSpeed;            /* ( millisecs for decompressing 320x240 on mac II)(0 if unknown)  */
  407.     UInt8                             compressionLevel;            /* measure (1-255) of compression level of this codec (0 if unknown)  */
  408.     UInt8                             resvd;                        /* pad */
  409.     short                             minimumHeight;                /* minimum height of image (block size) */
  410.     short                             minimumWidth;                /* minimum width of image (block size) */
  411.     short                             decompressPipelineLatency;    /* in milliseconds ( for asynchronous codecs ) */
  412.     short                             compressPipelineLatency;    /* in milliseconds ( for asynchronous codecs ) */
  413.     long                             privateData;
  414. };
  415. typedef struct CodecInfo                CodecInfo;
  416.  
  417. struct CodecNameSpec {
  418.     CodecComponent                     codec;
  419.     CodecType                         cType;
  420.     Str31                             typeName;
  421.     Handle                             name;
  422. };
  423. typedef struct CodecNameSpec            CodecNameSpec;
  424.  
  425. struct CodecNameSpecList {
  426.     short                             count;
  427.     CodecNameSpec                     list[1];
  428. };
  429. typedef struct CodecNameSpecList        CodecNameSpecList;
  430. typedef CodecNameSpecList *                CodecNameSpecListPtr;
  431. enum {
  432.     defaultDither                = 0,
  433.     forceDither                    = 1,
  434.     suppressDither                = 2,
  435.     useColorMatching            = 4
  436. };
  437.  
  438. enum {
  439.     callStdBits                    = 1,
  440.     callOldBits                    = 2,
  441.     noDefaultOpcodes            = 4
  442. };
  443.  
  444. enum {
  445.     graphicsModeStraightAlpha    = 256,
  446.     graphicsModePreWhiteAlpha    = 257,
  447.     graphicsModePreBlackAlpha    = 258,
  448.     graphicsModeComposition        = 259,
  449.     graphicsModeStraightAlphaBlend = 260,
  450.     graphicsModePreMulColorAlpha = 261
  451. };
  452.  
  453. enum {
  454.     evenField1ToEvenFieldOut    = 1 << 0,
  455.     evenField1ToOddFieldOut        = 1 << 1,
  456.     oddField1ToEvenFieldOut        = 1 << 2,
  457.     oddField1ToOddFieldOut        = 1 << 3,
  458.     evenField2ToEvenFieldOut    = 1 << 4,
  459.     evenField2ToOddFieldOut        = 1 << 5,
  460.     oddField2ToEvenFieldOut        = 1 << 6,
  461.     oddField2ToOddFieldOut        = 1 << 7
  462. };
  463.  
  464. enum {
  465.     icmFrameTimeHasVirtualStartTimeAndDuration = 1 << 0
  466. };
  467.  
  468.  
  469. struct ICMFrameTimeRecord {
  470.     wide                             value;                        /* frame time*/
  471.     long                             scale;                        /* timescale of value/duration fields*/
  472.     void *                            base;                        /* timebase*/
  473.  
  474.     long                             duration;                    /* duration frame is to be displayed (0 if unknown)*/
  475.     Fixed                             rate;                        /* rate of timebase relative to wall-time*/
  476.  
  477.     long                             recordSize;                    /* total number of bytes in ICMFrameTimeRecord*/
  478.  
  479.     long                             frameNumber;                /* number of frame, zero if not known*/
  480.  
  481.     long                             flags;
  482.  
  483.     wide                             virtualStartTime;            /* conceptual start time*/
  484.     long                             virtualDuration;            /* conceptual duration*/
  485. };
  486. typedef struct ICMFrameTimeRecord        ICMFrameTimeRecord;
  487.  
  488. typedef ICMFrameTimeRecord *            ICMFrameTimePtr;
  489. #if OPAQUE_UPP_TYPES
  490.     EXTERN_API(ICMDataUPP)
  491.     NewICMDataUPP                   (ICMDataProcPtr            userRoutine);
  492.  
  493.     EXTERN_API(ICMFlushUPP)
  494.     NewICMFlushUPP                   (ICMFlushProcPtr            userRoutine);
  495.  
  496.     EXTERN_API(ICMCompletionUPP)
  497.     NewICMCompletionUPP               (ICMCompletionProcPtr    userRoutine);
  498.  
  499.     EXTERN_API(ICMProgressUPP)
  500.     NewICMProgressUPP               (ICMProgressProcPtr        userRoutine);
  501.  
  502.     EXTERN_API(StdPixUPP)
  503.     NewStdPixUPP                   (StdPixProcPtr            userRoutine);
  504.  
  505.     EXTERN_API(QDPixUPP)
  506.     NewQDPixUPP                       (QDPixProcPtr            userRoutine);
  507.  
  508.     EXTERN_API(ICMAlignmentUPP)
  509.     NewICMAlignmentUPP               (ICMAlignmentProcPtr        userRoutine);
  510.  
  511.     EXTERN_API(ICMCursorShieldedUPP)
  512.     NewICMCursorShieldedUPP           (ICMCursorShieldedProcPtr userRoutine);
  513.  
  514.     EXTERN_API(ICMMemoryDisposedUPP)
  515.     NewICMMemoryDisposedUPP           (ICMMemoryDisposedProcPtr userRoutine);
  516.  
  517.     EXTERN_API(ICMConvertDataFormatUPP)
  518.     NewICMConvertDataFormatUPP       (ICMConvertDataFormatProcPtr userRoutine);
  519.  
  520.     EXTERN_API(void)
  521.     DisposeICMDataUPP               (ICMDataUPP                userUPP);
  522.  
  523.     EXTERN_API(void)
  524.     DisposeICMFlushUPP               (ICMFlushUPP                userUPP);
  525.  
  526.     EXTERN_API(void)
  527.     DisposeICMCompletionUPP           (ICMCompletionUPP        userUPP);
  528.  
  529.     EXTERN_API(void)
  530.     DisposeICMProgressUPP           (ICMProgressUPP            userUPP);
  531.  
  532.     EXTERN_API(void)
  533.     DisposeStdPixUPP               (StdPixUPP                userUPP);
  534.  
  535.     EXTERN_API(void)
  536.     DisposeQDPixUPP                   (QDPixUPP                userUPP);
  537.  
  538.     EXTERN_API(void)
  539.     DisposeICMAlignmentUPP           (ICMAlignmentUPP            userUPP);
  540.  
  541.     EXTERN_API(void)
  542.     DisposeICMCursorShieldedUPP       (ICMCursorShieldedUPP    userUPP);
  543.  
  544.     EXTERN_API(void)
  545.     DisposeICMMemoryDisposedUPP       (ICMMemoryDisposedUPP    userUPP);
  546.  
  547.     EXTERN_API(void)
  548.     DisposeICMConvertDataFormatUPP    (ICMConvertDataFormatUPP userUPP);
  549.  
  550.     EXTERN_API(OSErr)
  551.     InvokeICMDataUPP               (Ptr *                    dataP,
  552.                                     long                    bytesNeeded,
  553.                                     long                    refcon,
  554.                                     ICMDataUPP                userUPP);
  555.  
  556.     EXTERN_API(OSErr)
  557.     InvokeICMFlushUPP               (Ptr                        data,
  558.                                     long                    bytesAdded,
  559.                                     long                    refcon,
  560.                                     ICMFlushUPP                userUPP);
  561.  
  562.     EXTERN_API(void)
  563.     InvokeICMCompletionUPP           (OSErr                    result,
  564.                                     short                    flags,
  565.                                     long                    refcon,
  566.                                     ICMCompletionUPP        userUPP);
  567.  
  568.     EXTERN_API(OSErr)
  569.     InvokeICMProgressUPP           (short                    message,
  570.                                     Fixed                    completeness,
  571.                                     long                    refcon,
  572.                                     ICMProgressUPP            userUPP);
  573.  
  574.     EXTERN_API(void)
  575.     InvokeStdPixUPP                   (PixMap *                src,
  576.                                     Rect *                    srcRect,
  577.                                     MatrixRecord *            matrix,
  578.                                     short                    mode,
  579.                                     RgnHandle                mask,
  580.                                     PixMap *                matte,
  581.                                     Rect *                    matteRect,
  582.                                     short                    flags,
  583.                                     StdPixUPP                userUPP);
  584.  
  585.     EXTERN_API(void)
  586.     InvokeQDPixUPP                   (PixMap *                src,
  587.                                     Rect *                    srcRect,
  588.                                     MatrixRecord *            matrix,
  589.                                     short                    mode,
  590.                                     RgnHandle                mask,
  591.                                     PixMap *                matte,
  592.                                     Rect *                    matteRect,
  593.                                     short                    flags,
  594.                                     QDPixUPP                userUPP);
  595.  
  596.     EXTERN_API(void)
  597.     InvokeICMAlignmentUPP           (Rect *                    rp,
  598.                                     long                    refcon,
  599.                                     ICMAlignmentUPP            userUPP);
  600.  
  601.     EXTERN_API(void)
  602.     InvokeICMCursorShieldedUPP       (const Rect *            r,
  603.                                     void *                    refcon,
  604.                                     long                    flags,
  605.                                     ICMCursorShieldedUPP    userUPP);
  606.  
  607.     EXTERN_API(void)
  608.     InvokeICMMemoryDisposedUPP       (Ptr                        memoryBlock,
  609.                                     void *                    refcon,
  610.                                     ICMMemoryDisposedUPP    userUPP);
  611.  
  612.     EXTERN_API(OSErr)
  613.     InvokeICMConvertDataFormatUPP    (void *                refCon,
  614.                                     long                    flags,
  615.                                     Handle                    desiredFormat,
  616.                                     Handle                    sourceDataFormat,
  617.                                     void *                    srcData,
  618.                                     long                    srcDataSize,
  619.                                     void **                    dstData,
  620.                                     long *                    dstDataSize,
  621.                                     ICMConvertDataFormatUPP    userUPP);
  622.  
  623. #else
  624.     enum { uppICMDataProcInfo = 0x00000FE0 };                         /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes) */
  625.     enum { uppICMFlushProcInfo = 0x00000FE0 };                         /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes) */
  626.     enum { uppICMCompletionProcInfo = 0x00000E80 };                 /* pascal no_return_value Func(2_bytes, 2_bytes, 4_bytes) */
  627.     enum { uppICMProgressProcInfo = 0x00000FA0 };                     /* pascal 2_bytes Func(2_bytes, 4_bytes, 4_bytes) */
  628.     enum { uppStdPixProcInfo = 0x002FEFC0 };                         /* pascal no_return_value Func(4_bytes, 4_bytes, 4_bytes, 2_bytes, 4_bytes, 4_bytes, 4_bytes, 2_bytes) */
  629.     enum { uppQDPixProcInfo = 0x002FEFC0 };                         /* pascal no_return_value Func(4_bytes, 4_bytes, 4_bytes, 2_bytes, 4_bytes, 4_bytes, 4_bytes, 2_bytes) */
  630.     enum { uppICMAlignmentProcInfo = 0x000003C0 };                     /* pascal no_return_value Func(4_bytes, 4_bytes) */
  631.     enum { uppICMCursorShieldedProcInfo = 0x00000FC0 };             /* pascal no_return_value Func(4_bytes, 4_bytes, 4_bytes) */
  632.     enum { uppICMMemoryDisposedProcInfo = 0x000003C0 };             /* pascal no_return_value Func(4_bytes, 4_bytes) */
  633.     enum { uppICMConvertDataFormatProcInfo = 0x003FFFE0 };             /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes) */
  634.     #define NewICMDataUPP(userRoutine)                                 (ICMDataUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMDataProcInfo, GetCurrentArchitecture())
  635.     #define NewICMFlushUPP(userRoutine)                             (ICMFlushUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMFlushProcInfo, GetCurrentArchitecture())
  636.     #define NewICMCompletionUPP(userRoutine)                         (ICMCompletionUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMCompletionProcInfo, GetCurrentArchitecture())
  637.     #define NewICMProgressUPP(userRoutine)                             (ICMProgressUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMProgressProcInfo, GetCurrentArchitecture())
  638.     #define NewStdPixUPP(userRoutine)                                 (StdPixUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppStdPixProcInfo, GetCurrentArchitecture())
  639.     #define NewQDPixUPP(userRoutine)                                 (QDPixUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppQDPixProcInfo, GetCurrentArchitecture())
  640.     #define NewICMAlignmentUPP(userRoutine)                         (ICMAlignmentUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMAlignmentProcInfo, GetCurrentArchitecture())
  641.     #define NewICMCursorShieldedUPP(userRoutine)                     (ICMCursorShieldedUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMCursorShieldedProcInfo, GetCurrentArchitecture())
  642.     #define NewICMMemoryDisposedUPP(userRoutine)                     (ICMMemoryDisposedUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMMemoryDisposedProcInfo, GetCurrentArchitecture())
  643.     #define NewICMConvertDataFormatUPP(userRoutine)                 (ICMConvertDataFormatUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMConvertDataFormatProcInfo, GetCurrentArchitecture())
  644.     #define DisposeICMDataUPP(userUPP)                                 DisposeRoutineDescriptor(userUPP)
  645.     #define DisposeICMFlushUPP(userUPP)                             DisposeRoutineDescriptor(userUPP)
  646.     #define DisposeICMCompletionUPP(userUPP)                         DisposeRoutineDescriptor(userUPP)
  647.     #define DisposeICMProgressUPP(userUPP)                             DisposeRoutineDescriptor(userUPP)
  648.     #define DisposeStdPixUPP(userUPP)                                 DisposeRoutineDescriptor(userUPP)
  649.     #define DisposeQDPixUPP(userUPP)                                 DisposeRoutineDescriptor(userUPP)
  650.     #define DisposeICMAlignmentUPP(userUPP)                         DisposeRoutineDescriptor(userUPP)
  651.     #define DisposeICMCursorShieldedUPP(userUPP)                     DisposeRoutineDescriptor(userUPP)
  652.     #define DisposeICMMemoryDisposedUPP(userUPP)                     DisposeRoutineDescriptor(userUPP)
  653.     #define DisposeICMConvertDataFormatUPP(userUPP)                 DisposeRoutineDescriptor(userUPP)
  654.     #define InvokeICMDataUPP(dataP, bytesNeeded, refcon, userUPP)     (OSErr)CALL_THREE_PARAMETER_UPP((userUPP), uppICMDataProcInfo, (dataP), (bytesNeeded), (refcon))
  655.     #define InvokeICMFlushUPP(data, bytesAdded, refcon, userUPP)     (OSErr)CALL_THREE_PARAMETER_UPP((userUPP), uppICMFlushProcInfo, (data), (bytesAdded), (refcon))
  656.     #define InvokeICMCompletionUPP(result, flags, refcon, userUPP)     CALL_THREE_PARAMETER_UPP((userUPP), uppICMCompletionProcInfo, (result), (flags), (refcon))
  657.     #define InvokeICMProgressUPP(message, completeness, refcon, userUPP)  (OSErr)CALL_THREE_PARAMETER_UPP((userUPP), uppICMProgressProcInfo, (message), (completeness), (refcon))
  658.     #define InvokeStdPixUPP(src, srcRect, matrix, mode, mask, matte, matteRect, flags, userUPP)  CALL_EIGHT_PARAMETER_UPP((userUPP), uppStdPixProcInfo, (src), (srcRect), (matrix), (mode), (mask), (matte), (matteRect), (flags))
  659.     #define InvokeQDPixUPP(src, srcRect, matrix, mode, mask, matte, matteRect, flags, userUPP)  CALL_EIGHT_PARAMETER_UPP((userUPP), uppQDPixProcInfo, (src), (srcRect), (matrix), (mode), (mask), (matte), (matteRect), (flags))
  660.     #define InvokeICMAlignmentUPP(rp, refcon, userUPP)                 CALL_TWO_PARAMETER_UPP((userUPP), uppICMAlignmentProcInfo, (rp), (refcon))
  661.     #define InvokeICMCursorShieldedUPP(r, refcon, flags, userUPP)     CALL_THREE_PARAMETER_UPP((userUPP), uppICMCursorShieldedProcInfo, (r), (refcon), (flags))
  662.     #define InvokeICMMemoryDisposedUPP(memoryBlock, refcon, userUPP)  CALL_TWO_PARAMETER_UPP((userUPP), uppICMMemoryDisposedProcInfo, (memoryBlock), (refcon))
  663.     #define InvokeICMConvertDataFormatUPP(refCon, flags, desiredFormat, sourceDataFormat, srcData, srcDataSize, dstData, dstDataSize, userUPP)  (OSErr)CALL_EIGHT_PARAMETER_UPP((userUPP), uppICMConvertDataFormatProcInfo, (refCon), (flags), (desiredFormat), (sourceDataFormat), (srcData), (srcDataSize), (dstData), (dstDataSize))
  664. #endif
  665. /* support for pre-Carbon UPP routines: NewXXXProc and CallXXXProc */
  666. #define NewICMDataProc(userRoutine)                             NewICMDataUPP(userRoutine)
  667. #define NewICMFlushProc(userRoutine)                             NewICMFlushUPP(userRoutine)
  668. #define NewICMCompletionProc(userRoutine)                         NewICMCompletionUPP(userRoutine)
  669. #define NewICMProgressProc(userRoutine)                         NewICMProgressUPP(userRoutine)
  670. #define NewStdPixProc(userRoutine)                                 NewStdPixUPP(userRoutine)
  671. #define NewQDPixProc(userRoutine)                                 NewQDPixUPP(userRoutine)
  672. #define NewICMAlignmentProc(userRoutine)                         NewICMAlignmentUPP(userRoutine)
  673. #define NewICMCursorShieldedProc(userRoutine)                     NewICMCursorShieldedUPP(userRoutine)
  674. #define NewICMMemoryDisposedProc(userRoutine)                     NewICMMemoryDisposedUPP(userRoutine)
  675. #define NewICMConvertDataFormatProc(userRoutine)                 NewICMConvertDataFormatUPP(userRoutine)
  676. #define CallICMDataProc(userRoutine, dataP, bytesNeeded, refcon) InvokeICMDataUPP(dataP, bytesNeeded, refcon, userRoutine)
  677. #define CallICMFlushProc(userRoutine, data, bytesAdded, refcon)    InvokeICMFlushUPP(data, bytesAdded, refcon, userRoutine)
  678. #define CallICMCompletionProc(userRoutine, result, flags, refcon) InvokeICMCompletionUPP(result, flags, refcon, userRoutine)
  679. #define CallICMProgressProc(userRoutine, message, completeness, refcon) InvokeICMProgressUPP(message, completeness, refcon, userRoutine)
  680. #define CallStdPixProc(userRoutine, src, srcRect, matrix, mode, mask, matte, matteRect, flags) InvokeStdPixUPP(src, srcRect, matrix, mode, mask, matte, matteRect, flags, userRoutine)
  681. #define CallQDPixProc(userRoutine, src, srcRect, matrix, mode, mask, matte, matteRect, flags) InvokeQDPixUPP(src, srcRect, matrix, mode, mask, matte, matteRect, flags, userRoutine)
  682. #define CallICMAlignmentProc(userRoutine, rp, refcon)            InvokeICMAlignmentUPP(rp, refcon, userRoutine)
  683. #define CallICMCursorShieldedProc(userRoutine, r, refcon, flags) InvokeICMCursorShieldedUPP(r, refcon, flags, userRoutine)
  684. #define CallICMMemoryDisposedProc(userRoutine, memoryBlock, refcon) InvokeICMMemoryDisposedUPP(memoryBlock, refcon, userRoutine)
  685. #define CallICMConvertDataFormatProc(userRoutine, refCon, flags, desiredFormat, sourceDataFormat, srcData, srcDataSize, dstData, dstDataSize) InvokeICMConvertDataFormatUPP(refCon, flags, desiredFormat, sourceDataFormat, srcData, srcDataSize, dstData, dstDataSize, userRoutine)
  686. EXTERN_API( OSErr )
  687. CodecManagerVersion                (long *                    version)                            TWOWORDINLINE(0x7000, 0xAAA3);
  688.  
  689. EXTERN_API( OSErr )
  690. GetCodecNameList                (CodecNameSpecListPtr *    list,
  691.                                  short                     showAll)                            TWOWORDINLINE(0x7001, 0xAAA3);
  692.  
  693. EXTERN_API( OSErr )
  694. DisposeCodecNameList            (CodecNameSpecListPtr     list)                                TWOWORDINLINE(0x700F, 0xAAA3);
  695.  
  696. EXTERN_API( OSErr )
  697. GetCodecInfo                    (CodecInfo *            info,
  698.                                  CodecType                 cType,
  699.                                  CodecComponent         codec)                                TWOWORDINLINE(0x7003, 0xAAA3);
  700.  
  701. EXTERN_API( OSErr )
  702. GetMaxCompressionSize            (PixMapHandle             src,
  703.                                  const Rect *            srcRect,
  704.                                  short                     colorDepth,
  705.                                  CodecQ                 quality,
  706.                                  CodecType                 cType,
  707.                                  CompressorComponent     codec,
  708.                                  long *                    size)                                TWOWORDINLINE(0x7004, 0xAAA3);
  709.  
  710. EXTERN_API( OSErr )
  711. GetCSequenceMaxCompressionSize    (ImageSequence             seqID,
  712.                                  PixMapHandle             src,
  713.                                  long *                    size)                                FOURWORDINLINE(0x203C, 0x000C, 0x0074, 0xAAA3);
  714.  
  715. EXTERN_API( OSErr )
  716. GetCompressionTime                (PixMapHandle             src,
  717.                                  const Rect *            srcRect,
  718.                                  short                     colorDepth,
  719.                                  CodecType                 cType,
  720.                                  CompressorComponent     codec,
  721.                                  CodecQ *                spatialQuality,
  722.                                  CodecQ *                temporalQuality,
  723.                                  unsigned long *        compressTime)                        TWOWORDINLINE(0x7005, 0xAAA3);
  724.  
  725. EXTERN_API( OSErr )
  726. CompressImage                    (PixMapHandle             src,
  727.                                  const Rect *            srcRect,
  728.                                  CodecQ                 quality,
  729.                                  CodecType                 cType,
  730.                                  ImageDescriptionHandle  desc,
  731.                                  Ptr                     data)                                TWOWORDINLINE(0x7006, 0xAAA3);
  732.  
  733. EXTERN_API( OSErr )
  734. FCompressImage                    (PixMapHandle             src,
  735.                                  const Rect *            srcRect,
  736.                                  short                     colorDepth,
  737.                                  CodecQ                 quality,
  738.                                  CodecType                 cType,
  739.                                  CompressorComponent     codec,
  740.                                  CTabHandle             ctable,
  741.                                  CodecFlags             flags,
  742.                                  long                     bufferSize,
  743.                                  ICMFlushProcRecordPtr     flushProc,
  744.                                  ICMProgressProcRecordPtr  progressProc,
  745.                                  ImageDescriptionHandle  desc,
  746.                                  Ptr                     data)                                TWOWORDINLINE(0x7007, 0xAAA3);
  747.  
  748. EXTERN_API( OSErr )
  749. DecompressImage                    (Ptr                     data,
  750.                                  ImageDescriptionHandle  desc,
  751.                                  PixMapHandle             dst,
  752.                                  const Rect *            srcRect,
  753.                                  const Rect *            dstRect,
  754.                                  short                     mode,
  755.                                  RgnHandle                 mask)                                TWOWORDINLINE(0x7008, 0xAAA3);
  756.  
  757. EXTERN_API( OSErr )
  758. FDecompressImage                (Ptr                     data,
  759.                                  ImageDescriptionHandle  desc,
  760.                                  PixMapHandle             dst,
  761.                                  const Rect *            srcRect,
  762.                                  MatrixRecordPtr         matrix,
  763.                                  short                     mode,
  764.                                  RgnHandle                 mask,
  765.                                  PixMapHandle             matte,
  766.                                  const Rect *            matteRect,
  767.                                  CodecQ                 accuracy,
  768.                                  DecompressorComponent     codec,
  769.                                  long                     bufferSize,
  770.                                  ICMDataProcRecordPtr     dataProc,
  771.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x7009, 0xAAA3);
  772.  
  773. EXTERN_API( OSErr )
  774. CompressSequenceBegin            (ImageSequence *        seqID,
  775.                                  PixMapHandle             src,
  776.                                  PixMapHandle             prev,
  777.                                  const Rect *            srcRect,
  778.                                  const Rect *            prevRect,
  779.                                  short                     colorDepth,
  780.                                  CodecType                 cType,
  781.                                  CompressorComponent     codec,
  782.                                  CodecQ                 spatialQuality,
  783.                                  CodecQ                 temporalQuality,
  784.                                  long                     keyFrameRate,
  785.                                  CTabHandle             ctable,
  786.                                  CodecFlags             flags,
  787.                                  ImageDescriptionHandle  desc)                                TWOWORDINLINE(0x700A, 0xAAA3);
  788.  
  789. EXTERN_API( OSErr )
  790. CompressSequenceFrame            (ImageSequence             seqID,
  791.                                  PixMapHandle             src,
  792.                                  const Rect *            srcRect,
  793.                                  CodecFlags             flags,
  794.                                  Ptr                     data,
  795.                                  long *                    dataSize,
  796.                                  UInt8 *                similarity,
  797.                                  ICMCompletionProcRecordPtr  asyncCompletionProc)            TWOWORDINLINE(0x700B, 0xAAA3);
  798.  
  799. EXTERN_API( OSErr )
  800. DecompressSequenceBegin            (ImageSequence *        seqID,
  801.                                  ImageDescriptionHandle  desc,
  802.                                  CGrafPtr                 port,
  803.                                  GDHandle                 gdh,
  804.                                  const Rect *            srcRect,
  805.                                  MatrixRecordPtr         matrix,
  806.                                  short                     mode,
  807.                                  RgnHandle                 mask,
  808.                                  CodecFlags             flags,
  809.                                  CodecQ                 accuracy,
  810.                                  DecompressorComponent     codec)                                TWOWORDINLINE(0x700D, 0xAAA3);
  811.  
  812. EXTERN_API( OSErr )
  813. DecompressSequenceBeginS        (ImageSequence *        seqID,
  814.                                  ImageDescriptionHandle  desc,
  815.                                  Ptr                     data,
  816.                                  long                     dataSize,
  817.                                  CGrafPtr                 port,
  818.                                  GDHandle                 gdh,
  819.                                  const Rect *            srcRect,
  820.                                  MatrixRecordPtr         matrix,
  821.                                  short                     mode,
  822.                                  RgnHandle                 mask,
  823.                                  CodecFlags             flags,
  824.                                  CodecQ                 accuracy,
  825.                                  DecompressorComponent     codec)                                FOURWORDINLINE(0x203C, 0x0030, 0x005D, 0xAAA3);
  826.  
  827. EXTERN_API( OSErr )
  828. DecompressSequenceFrame            (ImageSequence             seqID,
  829.                                  Ptr                     data,
  830.                                  CodecFlags             inFlags,
  831.                                  CodecFlags *            outFlags,
  832.                                  ICMCompletionProcRecordPtr  asyncCompletionProc)            TWOWORDINLINE(0x700E, 0xAAA3);
  833.  
  834. EXTERN_API( OSErr )
  835. DecompressSequenceFrameS        (ImageSequence             seqID,
  836.                                  Ptr                     data,
  837.                                  long                     dataSize,
  838.                                  CodecFlags             inFlags,
  839.                                  CodecFlags *            outFlags,
  840.                                  ICMCompletionProcRecordPtr  asyncCompletionProc)            FOURWORDINLINE(0x203C, 0x0016, 0x0047, 0xAAA3);
  841.  
  842. EXTERN_API( OSErr )
  843. DecompressSequenceFrameWhen        (ImageSequence             seqID,
  844.                                  Ptr                     data,
  845.                                  long                     dataSize,
  846.                                  CodecFlags             inFlags,
  847.                                  CodecFlags *            outFlags,
  848.                                  ICMCompletionProcRecordPtr  asyncCompletionProc,
  849.                                  const ICMFrameTimeRecord * frameTime)                        FOURWORDINLINE(0x203C, 0x001A, 0x005E, 0xAAA3);
  850.  
  851. EXTERN_API( OSErr )
  852. CDSequenceFlush                    (ImageSequence             seqID)                                FOURWORDINLINE(0x203C, 0x0004, 0x005F, 0xAAA3);
  853.  
  854. EXTERN_API( OSErr )
  855. SetDSequenceMatrix                (ImageSequence             seqID,
  856.                                  MatrixRecordPtr         matrix)                                TWOWORDINLINE(0x7010, 0xAAA3);
  857.  
  858. EXTERN_API( OSErr )
  859. GetDSequenceMatrix                (ImageSequence             seqID,
  860.                                  MatrixRecordPtr         matrix)                                FOURWORDINLINE(0x203C, 0x0008, 0x0091, 0xAAA3);
  861.  
  862. EXTERN_API( OSErr )
  863. SetDSequenceMatte                (ImageSequence             seqID,
  864.                                  PixMapHandle             matte,
  865.                                  const Rect *            matteRect)                            TWOWORDINLINE(0x7011, 0xAAA3);
  866.  
  867. EXTERN_API( OSErr )
  868. SetDSequenceMask                (ImageSequence             seqID,
  869.                                  RgnHandle                 mask)                                TWOWORDINLINE(0x7012, 0xAAA3);
  870.  
  871. EXTERN_API( OSErr )
  872. SetDSequenceTransferMode        (ImageSequence             seqID,
  873.                                  short                     mode,
  874.                                  const RGBColor *        opColor)                            TWOWORDINLINE(0x7013, 0xAAA3);
  875.  
  876. EXTERN_API( OSErr )
  877. SetDSequenceDataProc            (ImageSequence             seqID,
  878.                                  ICMDataProcRecordPtr     dataProc,
  879.                                  long                     bufferSize)                            TWOWORDINLINE(0x7014, 0xAAA3);
  880.  
  881. EXTERN_API( OSErr )
  882. SetDSequenceAccuracy            (ImageSequence             seqID,
  883.                                  CodecQ                 accuracy)                            TWOWORDINLINE(0x7034, 0xAAA3);
  884.  
  885. EXTERN_API( OSErr )
  886. SetDSequenceSrcRect                (ImageSequence             seqID,
  887.                                  const Rect *            srcRect)                            TWOWORDINLINE(0x7035, 0xAAA3);
  888.  
  889. EXTERN_API( OSErr )
  890. SetDSequenceFlags                (ImageSequence             seqID,
  891.                                  long                     flags,
  892.                                  long                     flagsMask)                            FOURWORDINLINE(0x203C, 0x000C, 0x0057, 0xAAA3);
  893.  
  894. enum {
  895.     codecDSequenceSingleField    = (1L << 6)
  896. };
  897.  
  898.  
  899. EXTERN_API( OSErr )
  900. GetDSequenceImageBuffer            (ImageSequence             seqID,
  901.                                  GWorldPtr *            gworld)                                TWOWORDINLINE(0x7015, 0xAAA3);
  902.  
  903. EXTERN_API( OSErr )
  904. GetDSequenceScreenBuffer        (ImageSequence             seqID,
  905.                                  GWorldPtr *            gworld)                                TWOWORDINLINE(0x7016, 0xAAA3);
  906.  
  907. EXTERN_API( OSErr )
  908. SetCSequenceQuality                (ImageSequence             seqID,
  909.                                  CodecQ                 spatialQuality,
  910.                                  CodecQ                 temporalQuality)                    TWOWORDINLINE(0x7017, 0xAAA3);
  911.  
  912. EXTERN_API( OSErr )
  913. SetCSequencePrev                (ImageSequence             seqID,
  914.                                  PixMapHandle             prev,
  915.                                  const Rect *            prevRect)                            TWOWORDINLINE(0x7018, 0xAAA3);
  916.  
  917. EXTERN_API( OSErr )
  918. SetCSequenceFlushProc            (ImageSequence             seqID,
  919.                                  ICMFlushProcRecordPtr     flushProc,
  920.                                  long                     bufferSize)                            TWOWORDINLINE(0x7033, 0xAAA3);
  921.  
  922. EXTERN_API( OSErr )
  923. SetCSequenceKeyFrameRate        (ImageSequence             seqID,
  924.                                  long                     keyFrameRate)                        TWOWORDINLINE(0x7036, 0xAAA3);
  925.  
  926. EXTERN_API( OSErr )
  927. GetCSequenceKeyFrameRate        (ImageSequence             seqID,
  928.                                  long *                    keyFrameRate)                        FOURWORDINLINE(0x203C, 0x0008, 0x004B, 0xAAA3);
  929.  
  930. EXTERN_API( OSErr )
  931. GetCSequencePrevBuffer            (ImageSequence             seqID,
  932.                                  GWorldPtr *            gworld)                                TWOWORDINLINE(0x7019, 0xAAA3);
  933.  
  934. EXTERN_API( OSErr )
  935. CDSequenceBusy                    (ImageSequence             seqID)                                TWOWORDINLINE(0x701A, 0xAAA3);
  936.  
  937. EXTERN_API( OSErr )
  938. CDSequenceEnd                    (ImageSequence             seqID)                                TWOWORDINLINE(0x701B, 0xAAA3);
  939.  
  940. EXTERN_API( OSErr )
  941. CDSequenceEquivalentImageDescription (ImageSequence     seqID,
  942.                                  ImageDescriptionHandle  newDesc,
  943.                                  Boolean *                equivalent)                            FOURWORDINLINE(0x203C, 0x000C, 0x0065, 0xAAA3);
  944.  
  945. EXTERN_API( OSErr )
  946. GetCompressedImageSize            (ImageDescriptionHandle  desc,
  947.                                  Ptr                     data,
  948.                                  long                     bufferSize,
  949.                                  ICMDataProcRecordPtr     dataProc,
  950.                                  long *                    dataSize)                            TWOWORDINLINE(0x701C, 0xAAA3);
  951.  
  952. EXTERN_API( OSErr )
  953. GetSimilarity                    (PixMapHandle             src,
  954.                                  const Rect *            srcRect,
  955.                                  ImageDescriptionHandle  desc,
  956.                                  Ptr                     data,
  957.                                  Fixed *                similarity)                            TWOWORDINLINE(0x701D, 0xAAA3);
  958.  
  959. enum {
  960.     kImageDescriptionSampleFormat = FOUR_CHAR_CODE('idfm'),        /* image description extension describing sample format*/
  961.     kImageDescriptionClassicAtomFormat = FOUR_CHAR_CODE('atom'), /* sample contains classic atom structure (ie, GX codec and Curve codec)*/
  962.     kImageDescriptionQTAtomFormat = FOUR_CHAR_CODE('qtat'),        /* sample contains QT atom structure*/
  963.     kImageDescriptionEffectDataFormat = FOUR_CHAR_CODE('fxat'),    /* sample describes an effect (as QTAtoms)*/
  964.     kImageDescriptionPrivateDataFormat = FOUR_CHAR_CODE('priv'), /* sample is in a private codec specific format*/
  965.     kImageDescriptionAlternateCodec = FOUR_CHAR_CODE('subs'),    /* image description extension containing the OSType of a substitute codec should the main codec not be available*/
  966.     kImageDescriptionColorSpace    = FOUR_CHAR_CODE('cspc')        /* image description extension containing an OSType naming the native pixel format of an image (only used for pixel formats not supported by classic Color QuickDraw)*/
  967. };
  968.  
  969. EXTERN_API( OSErr )
  970. GetImageDescriptionCTable        (ImageDescriptionHandle  desc,
  971.                                  CTabHandle *            ctable)                                TWOWORDINLINE(0x701E, 0xAAA3);
  972.  
  973. EXTERN_API( OSErr )
  974. SetImageDescriptionCTable        (ImageDescriptionHandle  desc,
  975.                                  CTabHandle             ctable)                                TWOWORDINLINE(0x701F, 0xAAA3);
  976.  
  977. EXTERN_API( OSErr )
  978. GetImageDescriptionExtension    (ImageDescriptionHandle  desc,
  979.                                  Handle *                extension,
  980.                                  long                     idType,
  981.                                  long                     index)                                TWOWORDINLINE(0x7020, 0xAAA3);
  982.  
  983. EXTERN_API( OSErr )
  984. AddImageDescriptionExtension    (ImageDescriptionHandle  desc,
  985.                                  Handle                 extension,
  986.                                  long                     idType)                                TWOWORDINLINE(0x7021, 0xAAA3);
  987.  
  988. EXTERN_API( OSErr )
  989. RemoveImageDescriptionExtension    (ImageDescriptionHandle  desc,
  990.                                  long                     idType,
  991.                                  long                     index)                                FOURWORDINLINE(0x203C, 0x000C, 0x003A, 0xAAA3);
  992.  
  993. EXTERN_API( OSErr )
  994. CountImageDescriptionExtensionType (ImageDescriptionHandle  desc,
  995.                                  long                     idType,
  996.                                  long *                    count)                                FOURWORDINLINE(0x203C, 0x000C, 0x003B, 0xAAA3);
  997.  
  998. EXTERN_API( OSErr )
  999. GetNextImageDescriptionExtensionType (ImageDescriptionHandle  desc,
  1000.                                  long *                    idType)                                FOURWORDINLINE(0x203C, 0x0008, 0x003C, 0xAAA3);
  1001.  
  1002. EXTERN_API( OSErr )
  1003. FindCodec                        (CodecType                 cType,
  1004.                                  CodecComponent         specCodec,
  1005.                                  CompressorComponent *    compressor,
  1006.                                  DecompressorComponent * decompressor)                        TWOWORDINLINE(0x7023, 0xAAA3);
  1007.  
  1008. EXTERN_API( OSErr )
  1009. CompressPicture                    (PicHandle                 srcPicture,
  1010.                                  PicHandle                 dstPicture,
  1011.                                  CodecQ                 quality,
  1012.                                  CodecType                 cType)                                TWOWORDINLINE(0x7024, 0xAAA3);
  1013.  
  1014. EXTERN_API( OSErr )
  1015. FCompressPicture                (PicHandle                 srcPicture,
  1016.                                  PicHandle                 dstPicture,
  1017.                                  short                     colorDepth,
  1018.                                  CTabHandle             ctable,
  1019.                                  CodecQ                 quality,
  1020.                                  short                     doDither,
  1021.                                  short                     compressAgain,
  1022.                                  ICMProgressProcRecordPtr  progressProc,
  1023.                                  CodecType                 cType,
  1024.                                  CompressorComponent     codec)                                TWOWORDINLINE(0x7025, 0xAAA3);
  1025.  
  1026. EXTERN_API( OSErr )
  1027. CompressPictureFile                (short                     srcRefNum,
  1028.                                  short                     dstRefNum,
  1029.                                  CodecQ                 quality,
  1030.                                  CodecType                 cType)                                TWOWORDINLINE(0x7026, 0xAAA3);
  1031.  
  1032. EXTERN_API( OSErr )
  1033. FCompressPictureFile            (short                     srcRefNum,
  1034.                                  short                     dstRefNum,
  1035.                                  short                     colorDepth,
  1036.                                  CTabHandle             ctable,
  1037.                                  CodecQ                 quality,
  1038.                                  short                     doDither,
  1039.                                  short                     compressAgain,
  1040.                                  ICMProgressProcRecordPtr  progressProc,
  1041.                                  CodecType                 cType,
  1042.                                  CompressorComponent     codec)                                TWOWORDINLINE(0x7027, 0xAAA3);
  1043.  
  1044. EXTERN_API( OSErr )
  1045. GetPictureFileHeader            (short                     refNum,
  1046.                                  Rect *                    frame,
  1047.                                  OpenCPicParams *        header)                                TWOWORDINLINE(0x7028, 0xAAA3);
  1048.  
  1049. EXTERN_API( OSErr )
  1050. DrawPictureFile                    (short                     refNum,
  1051.                                  const Rect *            frame,
  1052.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x7029, 0xAAA3);
  1053.  
  1054. EXTERN_API( OSErr )
  1055. DrawTrimmedPicture                (PicHandle                 srcPicture,
  1056.                                  const Rect *            frame,
  1057.                                  RgnHandle                 trimMask,
  1058.                                  short                     doDither,
  1059.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702E, 0xAAA3);
  1060.  
  1061. EXTERN_API( OSErr )
  1062. DrawTrimmedPictureFile            (short                     srcRefnum,
  1063.                                  const Rect *            frame,
  1064.                                  RgnHandle                 trimMask,
  1065.                                  short                     doDither,
  1066.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702F, 0xAAA3);
  1067.  
  1068. EXTERN_API( OSErr )
  1069. MakeThumbnailFromPicture        (PicHandle                 picture,
  1070.                                  short                     colorDepth,
  1071.                                  PicHandle                 thumbnail,
  1072.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702A, 0xAAA3);
  1073.  
  1074. EXTERN_API( OSErr )
  1075. MakeThumbnailFromPictureFile    (short                     refNum,
  1076.                                  short                     colorDepth,
  1077.                                  PicHandle                 thumbnail,
  1078.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702B, 0xAAA3);
  1079.  
  1080. EXTERN_API( OSErr )
  1081. MakeThumbnailFromPixMap            (PixMapHandle             src,
  1082.                                  const Rect *            srcRect,
  1083.                                  short                     colorDepth,
  1084.                                  PicHandle                 thumbnail,
  1085.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702C, 0xAAA3);
  1086.  
  1087. EXTERN_API( OSErr )
  1088. TrimImage                        (ImageDescriptionHandle  desc,
  1089.                                  Ptr                     inData,
  1090.                                  long                     inBufferSize,
  1091.                                  ICMDataProcRecordPtr     dataProc,
  1092.                                  Ptr                     outData,
  1093.                                  long                     outBufferSize,
  1094.                                  ICMFlushProcRecordPtr     flushProc,
  1095.                                  Rect *                    trimRect,
  1096.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702D, 0xAAA3);
  1097.  
  1098. EXTERN_API( OSErr )
  1099. ConvertImage                    (ImageDescriptionHandle  srcDD,
  1100.                                  Ptr                     srcData,
  1101.                                  short                     colorDepth,
  1102.                                  CTabHandle             ctable,
  1103.                                  CodecQ                 accuracy,
  1104.                                  CodecQ                 quality,
  1105.                                  CodecType                 cType,
  1106.                                  CodecComponent         codec,
  1107.                                  ImageDescriptionHandle  dstDD,
  1108.                                  Ptr                     dstData)                            TWOWORDINLINE(0x7030, 0xAAA3);
  1109.  
  1110. EXTERN_API( OSErr )
  1111. GetCompressedPixMapInfo            (PixMapPtr                 pix,
  1112.                                  ImageDescriptionHandle * desc,
  1113.                                  Ptr *                    data,
  1114.                                  long *                    bufferSize,
  1115.                                  ICMDataProcRecord *    dataProc,
  1116.                                  ICMProgressProcRecord * progressProc)                        TWOWORDINLINE(0x7037, 0xAAA3);
  1117.  
  1118. EXTERN_API( OSErr )
  1119. SetCompressedPixMapInfo            (PixMapPtr                 pix,
  1120.                                  ImageDescriptionHandle  desc,
  1121.                                  Ptr                     data,
  1122.                                  long                     bufferSize,
  1123.                                  ICMDataProcRecordPtr     dataProc,
  1124.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x7038, 0xAAA3);
  1125.  
  1126. EXTERN_API( void )
  1127. StdPix                            (PixMapPtr                 src,
  1128.                                  const Rect *            srcRect,
  1129.                                  MatrixRecordPtr         matrix,
  1130.                                  short                     mode,
  1131.                                  RgnHandle                 mask,
  1132.                                  PixMapPtr                 matte,
  1133.                                  const Rect *            matteRect,
  1134.                                  short                     flags)                                TWOWORDINLINE(0x700C, 0xAAA3);
  1135.  
  1136. EXTERN_API( OSErr )
  1137. TransformRgn                    (MatrixRecordPtr         matrix,
  1138.                                  RgnHandle                 rgn)                                TWOWORDINLINE(0x7039, 0xAAA3);
  1139.  
  1140. /***********
  1141.     preview stuff
  1142. ***********/
  1143. EXTERN_API( void )
  1144. SFGetFilePreview                (Point                     where,
  1145.                                  ConstStr255Param         prompt,
  1146.                                  FileFilterUPP             fileFilter,
  1147.                                  short                     numTypes,
  1148.                                  ConstSFTypeListPtr     typeList,
  1149.                                  DlgHookUPP             dlgHook,
  1150.                                  SFReply *                reply)                                TWOWORDINLINE(0x7041, 0xAAA3);
  1151.  
  1152. EXTERN_API( void )
  1153. SFPGetFilePreview                (Point                     where,
  1154.                                  ConstStr255Param         prompt,
  1155.                                  FileFilterUPP             fileFilter,
  1156.                                  short                     numTypes,
  1157.                                  ConstSFTypeListPtr     typeList,
  1158.                                  DlgHookUPP             dlgHook,
  1159.                                  SFReply *                reply,
  1160.                                  short                     dlgID,
  1161.                                  ModalFilterUPP         filterProc)                            TWOWORDINLINE(0x7042, 0xAAA3);
  1162.  
  1163. EXTERN_API( void )
  1164. StandardGetFilePreview            (FileFilterUPP             fileFilter,
  1165.                                  short                     numTypes,
  1166.                                  ConstSFTypeListPtr     typeList,
  1167.                                  StandardFileReply *    reply)                                TWOWORDINLINE(0x7043, 0xAAA3);
  1168.  
  1169. EXTERN_API( void )
  1170. CustomGetFilePreview            (FileFilterYDUPP         fileFilter,
  1171.                                  short                     numTypes,
  1172.                                  ConstSFTypeListPtr     typeList,
  1173.                                  StandardFileReply *    reply,
  1174.                                  short                     dlgID,
  1175.                                  Point                     where,
  1176.                                  DlgHookYDUPP             dlgHook,
  1177.                                  ModalFilterYDUPP         filterProc,
  1178.                                  ActivationOrderListPtr  activeList,
  1179.                                  ActivateYDUPP             activateProc,
  1180.                                  void *                    yourDataPtr)                        TWOWORDINLINE(0x7044, 0xAAA3);
  1181.  
  1182. EXTERN_API( OSErr )
  1183. MakeFilePreview                    (short                     resRefNum,
  1184.                                  ICMProgressProcRecordPtr  progress)                        TWOWORDINLINE(0x7045, 0xAAA3);
  1185.  
  1186. EXTERN_API( OSErr )
  1187. AddFilePreview                    (short                     resRefNum,
  1188.                                  OSType                 previewType,
  1189.                                  Handle                 previewData)                        TWOWORDINLINE(0x7046, 0xAAA3);
  1190.  
  1191. enum {
  1192.     sfpItemPreviewAreaUser        = 11,
  1193.     sfpItemPreviewStaticText    = 12,
  1194.     sfpItemPreviewDividerUser    = 13,
  1195.     sfpItemCreatePreviewButton    = 14,
  1196.     sfpItemShowPreviewButton    = 15
  1197. };
  1198.  
  1199.  
  1200. struct PreviewResourceRecord {
  1201.     unsigned long                     modDate;
  1202.     short                             version;
  1203.     OSType                             resType;
  1204.     short                             resID;
  1205. };
  1206. typedef struct PreviewResourceRecord    PreviewResourceRecord;
  1207.  
  1208. typedef PreviewResourceRecord *            PreviewResourcePtr;
  1209. typedef PreviewResourcePtr *            PreviewResource;
  1210. EXTERN_API( void )
  1211. AlignScreenRect                    (Rect *                    rp,
  1212.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x0008, 0x004C, 0xAAA3);
  1213.  
  1214. EXTERN_API( void )
  1215. AlignWindow                        (WindowPtr                 wp,
  1216.                                  Boolean                 front,
  1217.                                  const Rect *            alignmentRect,
  1218.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x000E, 0x004D, 0xAAA3);
  1219.  
  1220. EXTERN_API( void )
  1221. DragAlignedWindow                (WindowPtr                 wp,
  1222.                                  Point                     startPt,
  1223.                                  Rect *                    boundsRect,
  1224.                                  Rect *                    alignmentRect,
  1225.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x0014, 0x004E, 0xAAA3);
  1226.  
  1227. EXTERN_API( long )
  1228. DragAlignedGrayRgn                (RgnHandle                 theRgn,
  1229.                                  Point                     startPt,
  1230.                                  Rect *                    boundsRect,
  1231.                                  Rect *                    slopRect,
  1232.                                  short                     axis,
  1233.                                  UniversalProcPtr         actionProc,
  1234.                                  Rect *                    alignmentRect,
  1235.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x001E, 0x004F, 0xAAA3);
  1236.  
  1237. EXTERN_API( OSErr )
  1238. SetCSequenceDataRateParams        (ImageSequence             seqID,
  1239.                                  DataRateParamsPtr         params)                                FOURWORDINLINE(0x203C, 0x0008, 0x0050, 0xAAA3);
  1240.  
  1241. EXTERN_API( OSErr )
  1242. SetCSequenceFrameNumber            (ImageSequence             seqID,
  1243.                                  long                     frameNumber)                        FOURWORDINLINE(0x203C, 0x0008, 0x0051, 0xAAA3);
  1244.  
  1245. EXTERN_API( OSErr )
  1246. SetCSequencePreferredPacketSize    (ImageSequence             seqID,
  1247.                                  long                     preferredPacketSizeInBytes)            FOURWORDINLINE(0x203C, 0x0008, 0x0078, 0xAAA3);
  1248.  
  1249. EXTERN_API( OSErr )
  1250. NewImageGWorld                    (GWorldPtr *            gworld,
  1251.                                  ImageDescriptionHandle  idh,
  1252.                                  GWorldFlags             flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x0052, 0xAAA3);
  1253.  
  1254. EXTERN_API( OSErr )
  1255. GetCSequenceDataRateParams        (ImageSequence             seqID,
  1256.                                  DataRateParamsPtr         params)                                FOURWORDINLINE(0x203C, 0x0008, 0x0053, 0xAAA3);
  1257.  
  1258. EXTERN_API( OSErr )
  1259. GetCSequenceFrameNumber            (ImageSequence             seqID,
  1260.                                  long *                    frameNumber)                        FOURWORDINLINE(0x203C, 0x0008, 0x0054, 0xAAA3);
  1261.  
  1262. EXTERN_API( OSErr )
  1263. GetBestDeviceRect                (GDHandle *                gdh,
  1264.                                  Rect *                    rp)                                    FOURWORDINLINE(0x203C, 0x0008, 0x0055, 0xAAA3);
  1265.  
  1266. EXTERN_API( OSErr )
  1267. SetSequenceProgressProc            (ImageSequence             seqID,
  1268.                                  ICMProgressProcRecord * progressProc)                        FOURWORDINLINE(0x203C, 0x0008, 0x0056, 0xAAA3);
  1269.  
  1270. EXTERN_API( OSErr )
  1271. GDHasScale                        (GDHandle                 gdh,
  1272.                                  short                     depth,
  1273.                                  Fixed *                scale)                                FOURWORDINLINE(0x203C, 0x000A, 0x005A, 0xAAA3);
  1274.  
  1275. EXTERN_API( OSErr )
  1276. GDGetScale                        (GDHandle                 gdh,
  1277.                                  Fixed *                scale,
  1278.                                  short *                flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x005B, 0xAAA3);
  1279.  
  1280. EXTERN_API( OSErr )
  1281. GDSetScale                        (GDHandle                 gdh,
  1282.                                  Fixed                     scale,
  1283.                                  short                     flags)                                FOURWORDINLINE(0x203C, 0x000A, 0x005C, 0xAAA3);
  1284.  
  1285. EXTERN_API( OSErr )
  1286. ICMShieldSequenceCursor            (ImageSequence             seqID)                                FOURWORDINLINE(0x203C, 0x0004, 0x0062, 0xAAA3);
  1287.  
  1288. EXTERN_API( void )
  1289. ICMDecompressComplete            (ImageSequence             seqID,
  1290.                                  OSErr                     err,
  1291.                                  short                     flag,
  1292.                                  ICMCompletionProcRecordPtr  completionRtn)                    FOURWORDINLINE(0x203C, 0x000C, 0x0063, 0xAAA3);
  1293.  
  1294. EXTERN_API( OSErr )
  1295. ICMDecompressCompleteS            (ImageSequence             seqID,
  1296.                                  OSErr                     err,
  1297.                                  short                     flag,
  1298.                                  ICMCompletionProcRecordPtr  completionRtn)                    FOURWORDINLINE(0x203C, 0x000C, 0x0082, 0xAAA3);
  1299.  
  1300. EXTERN_API( OSErr )
  1301. ICMSequenceLockBits                (ImageSequence             seqID,
  1302.                                  PixMapPtr                 dst,
  1303.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x007C, 0xAAA3);
  1304.  
  1305. EXTERN_API( OSErr )
  1306. ICMSequenceUnlockBits            (ImageSequence             seqID,
  1307.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x0008, 0x007D, 0xAAA3);
  1308.  
  1309. enum {
  1310.     kICMPixelFormatIsPlanarMask    = 0x0F,
  1311.     kICMPixelFormatIsIndexed    = (1L << 4),
  1312.     kICMPixelFormatIsSupportedByQD = (1L << 5)
  1313. };
  1314.  
  1315.  
  1316. struct ICMPixelFormatInfo {
  1317.     long                             size;
  1318.     unsigned long                     formatFlags;
  1319.     short                             bitsPerPixel[14];
  1320.     long                             reservedSetToZero;
  1321. };
  1322. typedef struct ICMPixelFormatInfo        ICMPixelFormatInfo;
  1323. typedef ICMPixelFormatInfo *            ICMPixelFormatInfoPtr;
  1324. EXTERN_API( OSErr )
  1325. ICMGetPixelFormatInfo            (OSType                 PixelFormat,
  1326.                                  ICMPixelFormatInfoPtr     theInfo)                            FOURWORDINLINE(0x203C, 0x0008, 0x0083, 0xAAA3);
  1327.  
  1328. EXTERN_API( OSErr )
  1329. ICMSetPixelFormatInfo            (OSType                 PixelFormat,
  1330.                                  ICMPixelFormatInfoPtr     theInfo)                            FOURWORDINLINE(0x203C, 0x0008, 0x008A, 0xAAA3);
  1331.  
  1332. enum {
  1333.     kICMGetChainUltimateParent    = 0,
  1334.     kICMGetChainParent            = 1,
  1335.     kICMGetChainChild            = 2,
  1336.     kICMGetChainUltimateChild    = 3
  1337. };
  1338.  
  1339. EXTERN_API( OSErr )
  1340. ICMSequenceGetChainMember        (ImageSequence             seqID,
  1341.                                  ImageSequence *        retSeqID,
  1342.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x007E, 0xAAA3);
  1343.  
  1344. EXTERN_API( OSErr )
  1345. SetDSequenceTimeCode            (ImageSequence             seqID,
  1346.                                  void *                    timeCodeFormat,
  1347.                                  void *                    timeCodeTime)                        FOURWORDINLINE(0x203C, 0x000C, 0x0064, 0xAAA3);
  1348.  
  1349. EXTERN_API( OSErr )
  1350. CDSequenceNewMemory                (ImageSequence             seqID,
  1351.                                  Ptr *                    data,
  1352.                                  Size                     dataSize,
  1353.                                  long                     dataUse,
  1354.                                  ICMMemoryDisposedUPP     memoryGoneProc,
  1355.                                  void *                    refCon)                                FOURWORDINLINE(0x203C, 0x0018, 0x0066, 0xAAA3);
  1356.  
  1357. EXTERN_API( OSErr )
  1358. CDSequenceDisposeMemory            (ImageSequence             seqID,
  1359.                                  Ptr                     data)                                FOURWORDINLINE(0x203C, 0x0008, 0x0067, 0xAAA3);
  1360.  
  1361. EXTERN_API( OSErr )
  1362. CDSequenceNewDataSource            (ImageSequence             seqID,
  1363.                                  ImageSequenceDataSource * sourceID,
  1364.                                  OSType                 sourceType,
  1365.                                  long                     sourceInputNumber,
  1366.                                  Handle                 dataDescription,
  1367.                                  ICMConvertDataFormatUPP  transferProc,
  1368.                                  void *                    refCon)                                FOURWORDINLINE(0x203C, 0x001C, 0x0068, 0xAAA3);
  1369.  
  1370. EXTERN_API( OSErr )
  1371. CDSequenceDisposeDataSource        (ImageSequenceDataSource  sourceID)                            FOURWORDINLINE(0x203C, 0x0004, 0x0069, 0xAAA3);
  1372.  
  1373. EXTERN_API( OSErr )
  1374. CDSequenceSetSourceData            (ImageSequenceDataSource  sourceID,
  1375.                                  void *                    data,
  1376.                                  long                     dataSize)                            FOURWORDINLINE(0x203C, 0x000C, 0x006A, 0xAAA3);
  1377.  
  1378. EXTERN_API( OSErr )
  1379. CDSequenceChangedSourceData        (ImageSequenceDataSource  sourceID)                            FOURWORDINLINE(0x203C, 0x0004, 0x006B, 0xAAA3);
  1380.  
  1381. EXTERN_API( OSErr )
  1382. CDSequenceSetSourceDataQueue    (ImageSequenceDataSource  sourceID,
  1383.                                  QHdrPtr                 dataQueue)                            FOURWORDINLINE(0x203C, 0x0008, 0x007B, 0xAAA3);
  1384.  
  1385. EXTERN_API( OSErr )
  1386. CDSequenceGetDataSource            (ImageSequence             seqID,
  1387.                                  ImageSequenceDataSource * sourceID,
  1388.                                  OSType                 sourceType,
  1389.                                  long                     sourceInputNumber)                    FOURWORDINLINE(0x203C, 0x0010, 0x007F, 0xAAA3);
  1390.  
  1391. EXTERN_API( OSErr )
  1392. PtInDSequenceData                (ImageSequence             seqID,
  1393.                                  void *                    data,
  1394.                                  Size                     dataSize,
  1395.                                  Point                     where,
  1396.                                  Boolean *                hit)                                FOURWORDINLINE(0x203C, 0x0014, 0x006C, 0xAAA3);
  1397.  
  1398. EXTERN_API( OSErr )
  1399. HitTestDSequenceData            (ImageSequence             seqID,
  1400.                                  void *                    data,
  1401.                                  Size                     dataSize,
  1402.                                  Point                     where,
  1403.                                  long *                    hit,
  1404.                                  long                     hitFlags)                            FOURWORDINLINE(0x203C, 0x0006, 0x0087, 0xAAA3);
  1405.  
  1406. EXTERN_API( OSErr )
  1407. GetGraphicsImporterForFile        (const FSSpec *            theFile,
  1408.                                  ComponentInstance *    gi)                                    FOURWORDINLINE(0x203C, 0x0008, 0x006E, 0xAAA3);
  1409.  
  1410. EXTERN_API( OSErr )
  1411. GetGraphicsImporterForDataRef    (Handle                 dataRef,
  1412.                                  OSType                 dataRefType,
  1413.                                  ComponentInstance *    gi)                                    FOURWORDINLINE(0x203C, 0x000C, 0x0077, 0xAAA3);
  1414.  
  1415. enum {
  1416.     kDontUseValidateToFindGraphicsImporter = 1L << 0
  1417. };
  1418.  
  1419. EXTERN_API( OSErr )
  1420. GetGraphicsImporterForFileWithFlags (const FSSpec *        theFile,
  1421.                                  ComponentInstance *    gi,
  1422.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x0084, 0xAAA3);
  1423.  
  1424. EXTERN_API( OSErr )
  1425. GetGraphicsImporterForDataRefWithFlags (Handle             dataRef,
  1426.                                  OSType                 dataRefType,
  1427.                                  ComponentInstance *    gi,
  1428.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x0010, 0x0085, 0xAAA3);
  1429.  
  1430. EXTERN_API( OSErr )
  1431. QTGetFileNameExtension            (ConstStrFileNameParam     fileName,
  1432.                                  OSType                 fileType,
  1433.                                  OSType *                extension)                            FOURWORDINLINE(0x203C, 0x000C, 0x0061, 0xAAA3);
  1434.  
  1435.  
  1436. EXTERN_API( OSErr )
  1437. ImageTranscodeSequenceBegin        (ImageTranscodeSequence * its,
  1438.                                  ImageDescriptionHandle  srcDesc,
  1439.                                  OSType                 destType,
  1440.                                  ImageDescriptionHandle * dstDesc,
  1441.                                  void *                    data,
  1442.                                  long                     dataSize)                            FOURWORDINLINE(0x203C, 0x0018, 0x006F, 0xAAA3);
  1443.  
  1444. EXTERN_API( OSErr )
  1445. ImageTranscodeSequenceEnd        (ImageTranscodeSequence  its)                                FOURWORDINLINE(0x203C, 0x0004, 0x0070, 0xAAA3);
  1446.  
  1447. EXTERN_API( OSErr )
  1448. ImageTranscodeFrame                (ImageTranscodeSequence  its,
  1449.                                  void *                    srcData,
  1450.                                  long                     srcDataSize,
  1451.                                  void **                dstData,
  1452.                                  long *                    dstDataSize)                        FOURWORDINLINE(0x203C, 0x0014, 0x0071, 0xAAA3);
  1453.  
  1454. EXTERN_API( OSErr )
  1455. ImageTranscodeDisposeFrameData    (ImageTranscodeSequence  its,
  1456.                                  void *                    dstData)                            FOURWORDINLINE(0x203C, 0x0008, 0x0072, 0xAAA3);
  1457.  
  1458. EXTERN_API( OSErr )
  1459. CDSequenceInvalidate            (ImageSequence             seqID,
  1460.                                  RgnHandle                 invalRgn)                            FOURWORDINLINE(0x203C, 0x0008, 0x0073, 0xAAA3);
  1461.  
  1462. EXTERN_API( OSErr )
  1463. CDSequenceSetTimeBase            (ImageSequence             seqID,
  1464.                                  void *                    base)                                FOURWORDINLINE(0x203C, 0x0008, 0x0079, 0xAAA3);
  1465.  
  1466. EXTERN_API( OSErr )
  1467. ImageFieldSequenceBegin            (ImageFieldSequence *    ifs,
  1468.                                  ImageDescriptionHandle  desc1,
  1469.                                  ImageDescriptionHandle  desc2,
  1470.                                  ImageDescriptionHandle  descOut)                            FOURWORDINLINE(0x203C, 0x0010, 0x006D, 0xAAA3);
  1471.  
  1472. EXTERN_API( OSErr )
  1473. ImageFieldSequenceExtractCombine (ImageFieldSequence     ifs,
  1474.                                  long                     fieldFlags,
  1475.                                  void *                    data1,
  1476.                                  long                     dataSize1,
  1477.                                  void *                    data2,
  1478.                                  long                     dataSize2,
  1479.                                  void *                    outputData,
  1480.                                  long *                    outDataSize)                        FOURWORDINLINE(0x203C, 0x0020, 0x0075, 0xAAA3);
  1481.  
  1482. EXTERN_API( OSErr )
  1483. ImageFieldSequenceEnd            (ImageFieldSequence     ifs)                                FOURWORDINLINE(0x203C, 0x0004, 0x0076, 0xAAA3);
  1484.  
  1485. enum {
  1486.     kICMTempThenAppMemory        = 1L << 12,
  1487.     kICMAppThenTempMemory        = 1L << 13
  1488. };
  1489.  
  1490. EXTERN_API( OSErr )
  1491. QTNewGWorld                        (GWorldPtr *            offscreenGWorld,
  1492.                                  OSType                 PixelFormat,
  1493.                                  const Rect *            boundsRect,
  1494.                                  CTabHandle             cTable,
  1495.                                  GDHandle                 aGDevice,
  1496.                                  GWorldFlags             flags)                                FOURWORDINLINE(0x203C, 0x0018, 0x0080, 0xAAA3);
  1497.  
  1498. EXTERN_API( OSErr )
  1499. QTNewGWorldFromPtr                (GWorldPtr *            gw,
  1500.                                  OSType                 pixelFormat,
  1501.                                  const Rect *            boundsRect,
  1502.                                  CTabHandle             cTable,
  1503.                                  GDHandle                 aGDevice,
  1504.                                  GWorldFlags             flags,
  1505.                                  void *                    baseAddr,
  1506.                                  long                     rowBytes)                            FOURWORDINLINE(0x203C, 0x0020, 0x008B, 0xAAA3);
  1507.  
  1508. EXTERN_API( GWorldFlags )
  1509. QTUpdateGWorld                    (GWorldPtr *            offscreenGWorld,
  1510.                                  OSType                 PixelFormat,
  1511.                                  const Rect *            boundsRect,
  1512.                                  CTabHandle             cTable,
  1513.                                  GDHandle                 aGDevice,
  1514.                                  GWorldFlags             flags)                                FOURWORDINLINE(0x203C, 0x0018, 0x0081, 0xAAA3);
  1515.  
  1516. EXTERN_API( OSErr )
  1517. MakeImageDescriptionForPixMap    (PixMapHandle             pixmap,
  1518.                                  ImageDescriptionHandle * idh)                                FOURWORDINLINE(0x203C, 0x0008, 0x007A, 0xAAA3);
  1519.  
  1520. EXTERN_API( OSErr )
  1521. MakeImageDescriptionForEffect    (OSType                 effectType,
  1522.                                  ImageDescriptionHandle * idh)                                FOURWORDINLINE(0x203C, 0x0008, 0x0092, 0xAAA3);
  1523.  
  1524. EXTERN_API( short )
  1525. QTGetPixelSize                    (OSType                 PixelFormat)                        FOURWORDINLINE(0x203C, 0x0004, 0x0086, 0xAAA3);
  1526.  
  1527. EXTERN_API( long )
  1528. QTGetPixMapPtrRowBytes            (PixMapPtr                 pm)                                    FOURWORDINLINE(0x203C, 0x0004, 0x008D, 0xAAA3);
  1529.  
  1530. EXTERN_API( long )
  1531. QTGetPixMapHandleRowBytes        (PixMapHandle             pm)                                    FOURWORDINLINE(0x203C, 0x0004, 0x008E, 0xAAA3);
  1532.  
  1533. EXTERN_API( OSErr )
  1534. QTSetPixMapPtrRowBytes            (PixMapPtr                 pm,
  1535.                                  long                     rowBytes)                            FOURWORDINLINE(0x203C, 0x0008, 0x0090, 0xAAA3);
  1536.  
  1537. EXTERN_API( OSErr )
  1538. QTSetPixMapHandleRowBytes        (PixMapHandle             pm,
  1539.                                  long                     rowBytes)                            FOURWORDINLINE(0x203C, 0x0008, 0x008F, 0xAAA3);
  1540.  
  1541. EXTERN_API( OSErr )
  1542. QuadToQuadMatrix                (const Fixed *            source,
  1543.                                  const Fixed *            dest,
  1544.                                  MatrixRecord *            map)                                FOURWORDINLINE(0x203C, 0x000C, 0x0095, 0xAAA3);
  1545.  
  1546.  
  1547.  
  1548. enum {
  1549.     identityMatrixType            = 0x00,                            /* result if matrix is identity */
  1550.     translateMatrixType            = 0x01,                            /* result if matrix translates */
  1551.     scaleMatrixType                = 0x02,                            /* result if matrix scales */
  1552.     scaleTranslateMatrixType    = 0x03,                            /* result if matrix scales and translates */
  1553.     linearMatrixType            = 0x04,                            /* result if matrix is general 2 x 2 */
  1554.     linearTranslateMatrixType    = 0x05,                            /* result if matrix is general 2 x 2 and translates */
  1555.     perspectiveMatrixType        = 0x06                            /* result if matrix is general 3 x 3 */
  1556. };
  1557.  
  1558.  
  1559. typedef unsigned short                     MatrixFlags;
  1560. EXTERN_API( short )
  1561. GetMatrixType                    (const MatrixRecord *    m)                                    TWOWORDINLINE(0x7014, 0xABC2);
  1562.  
  1563. EXTERN_API( void )
  1564. CopyMatrix                        (const MatrixRecord *    m1,
  1565.                                  MatrixRecord *            m2)                                    TWOWORDINLINE(0x7020, 0xABC2);
  1566.  
  1567. EXTERN_API( Boolean )
  1568. EqualMatrix                        (const MatrixRecord *    m1,
  1569.                                  const MatrixRecord *    m2)                                    TWOWORDINLINE(0x7021, 0xABC2);
  1570.  
  1571. EXTERN_API( void )
  1572. SetIdentityMatrix                (MatrixRecord *            matrix)                                TWOWORDINLINE(0x7015, 0xABC2);
  1573.  
  1574. EXTERN_API( void )
  1575. TranslateMatrix                    (MatrixRecord *            m,
  1576.                                  Fixed                     deltaH,
  1577.                                  Fixed                     deltaV)                                TWOWORDINLINE(0x7019, 0xABC2);
  1578.  
  1579. EXTERN_API( void )
  1580. RotateMatrix                    (MatrixRecord *            m,
  1581.                                  Fixed                     degrees,
  1582.                                  Fixed                     aboutX,
  1583.                                  Fixed                     aboutY)                                TWOWORDINLINE(0x7016, 0xABC2);
  1584.  
  1585. EXTERN_API( void )
  1586. ScaleMatrix                        (MatrixRecord *            m,
  1587.                                  Fixed                     scaleX,
  1588.                                  Fixed                     scaleY,
  1589.                                  Fixed                     aboutX,
  1590.                                  Fixed                     aboutY)                                TWOWORDINLINE(0x7017, 0xABC2);
  1591.  
  1592. EXTERN_API( void )
  1593. SkewMatrix                        (MatrixRecord *            m,
  1594.                                  Fixed                     skewX,
  1595.                                  Fixed                     skewY,
  1596.                                  Fixed                     aboutX,
  1597.                                  Fixed                     aboutY)                                TWOWORDINLINE(0x7018, 0xABC2);
  1598.  
  1599. EXTERN_API( OSErr )
  1600. TransformFixedPoints            (const MatrixRecord *    m,
  1601.                                  FixedPoint *            fpt,
  1602.                                  long                     count)                                TWOWORDINLINE(0x7022, 0xABC2);
  1603.  
  1604. EXTERN_API( OSErr )
  1605. TransformPoints                    (const MatrixRecord *    mp,
  1606.                                  Point *                pt1,
  1607.                                  long                     count)                                TWOWORDINLINE(0x7023, 0xABC2);
  1608.  
  1609. EXTERN_API( Boolean )
  1610. TransformFixedRect                (const MatrixRecord *    m,
  1611.                                  FixedRect *            fr,
  1612.                                  FixedPoint *            fpp)                                TWOWORDINLINE(0x7024, 0xABC2);
  1613.  
  1614. EXTERN_API( Boolean )
  1615. TransformRect                    (const MatrixRecord *    m,
  1616.                                  Rect *                    r,
  1617.                                  FixedPoint *            fpp)                                TWOWORDINLINE(0x7025, 0xABC2);
  1618.  
  1619. EXTERN_API( Boolean )
  1620. InverseMatrix                    (const MatrixRecord *    m,
  1621.                                  MatrixRecord *            im)                                    TWOWORDINLINE(0x701C, 0xABC2);
  1622.  
  1623. EXTERN_API( void )
  1624. ConcatMatrix                    (const MatrixRecord *    a,
  1625.                                  MatrixRecord *            b)                                    TWOWORDINLINE(0x701B, 0xABC2);
  1626.  
  1627. EXTERN_API( void )
  1628. RectMatrix                        (MatrixRecord *            matrix,
  1629.                                  const Rect *            srcRect,
  1630.                                  const Rect *            dstRect)                            TWOWORDINLINE(0x701E, 0xABC2);
  1631.  
  1632. EXTERN_API( void )
  1633. MapMatrix                        (MatrixRecord *            matrix,
  1634.                                  const Rect *            fromRect,
  1635.                                  const Rect *            toRect)                                TWOWORDINLINE(0x701D, 0xABC2);
  1636.  
  1637.  
  1638.  
  1639.  
  1640.  
  1641.  
  1642.  
  1643. EXTERN_API( void )
  1644. CompAdd                            (wide *                    src,
  1645.                                  wide *                    dst)                                TWOWORDINLINE(0x7001, 0xABC2);
  1646.  
  1647. EXTERN_API( void )
  1648. CompSub                            (wide *                    src,
  1649.                                  wide *                    dst)                                TWOWORDINLINE(0x7002, 0xABC2);
  1650.  
  1651. EXTERN_API( void )
  1652. CompNeg                            (wide *                    dst)                                TWOWORDINLINE(0x7003, 0xABC2);
  1653.  
  1654. EXTERN_API( void )
  1655. CompShift                        (wide *                    src,
  1656.                                  short                     shift)                                TWOWORDINLINE(0x7004, 0xABC2);
  1657.  
  1658. EXTERN_API( void )
  1659. CompMul                            (long                     src1,
  1660.                                  long                     src2,
  1661.                                  wide *                    dst)                                TWOWORDINLINE(0x7005, 0xABC2);
  1662.  
  1663. EXTERN_API( long )
  1664. CompDiv                            (wide *                    numerator,
  1665.                                  long                     denominator,
  1666.                                  long *                    remainder)                            TWOWORDINLINE(0x7006, 0xABC2);
  1667.  
  1668. EXTERN_API( void )
  1669. CompFixMul                        (wide *                    compSrc,
  1670.                                  Fixed                     fixSrc,
  1671.                                  wide *                    compDst)                            TWOWORDINLINE(0x7007, 0xABC2);
  1672.  
  1673. EXTERN_API( void )
  1674. CompMulDiv                        (wide *                    co,
  1675.                                  long                     mul,
  1676.                                  long                     divisor)                            TWOWORDINLINE(0x7008, 0xABC2);
  1677.  
  1678. EXTERN_API( void )
  1679. CompMulDivTrunc                    (wide *                    co,
  1680.                                  long                     mul,
  1681.                                  long                     divisor,
  1682.                                  long *                    remainder)                            TWOWORDINLINE(0x700C, 0xABC2);
  1683.  
  1684. EXTERN_API( long )
  1685. CompCompare                        (const wide *            a,
  1686.                                  const wide *            minusb)                                TWOWORDINLINE(0x7009, 0xABC2);
  1687.  
  1688. EXTERN_API( unsigned long )
  1689. CompSquareRoot                    (const wide *            src)                                TWOWORDINLINE(0x7011, 0xABC2);
  1690.  
  1691. EXTERN_API( Fixed )
  1692. FixMulDiv                        (Fixed                     src,
  1693.                                  Fixed                     mul,
  1694.                                  Fixed                     divisor)                            TWOWORDINLINE(0x700A, 0xABC2);
  1695.  
  1696. EXTERN_API( Fixed )
  1697. UnsignedFixMulDiv                (Fixed                     src,
  1698.                                  Fixed                     mul,
  1699.                                  Fixed                     divisor)                            TWOWORDINLINE(0x700D, 0xABC2);
  1700.  
  1701. EXTERN_API( Fract )
  1702. FracSinCos                        (Fixed                     degree,
  1703.                                  Fract *                cosOut)                                TWOWORDINLINE(0x700B, 0xABC2);
  1704.  
  1705. EXTERN_API( Fixed )
  1706. FixExp2                            (Fixed                     src)                                TWOWORDINLINE(0x700E, 0xABC2);
  1707.  
  1708. EXTERN_API( Fixed )
  1709. FixLog2                            (Fixed                     src)                                TWOWORDINLINE(0x700F, 0xABC2);
  1710.  
  1711. EXTERN_API( Fixed )
  1712. FixPow                            (Fixed                     base,
  1713.                                  Fixed                     exp)                                TWOWORDINLINE(0x7010, 0xABC2);
  1714.  
  1715.  
  1716.  
  1717.  
  1718. typedef ComponentInstance                 GraphicsImportComponent;
  1719. enum {
  1720.     GraphicsImporterComponentType = FOUR_CHAR_CODE('grip')
  1721. };
  1722.  
  1723. enum {
  1724.     graphicsImporterUsesImageDecompressor = 1L << 23
  1725. };
  1726.  
  1727. enum {
  1728.     quickTimeImageFileImageDescriptionAtom = FOUR_CHAR_CODE('idsc'),
  1729.     quickTimeImageFileImageDataAtom = FOUR_CHAR_CODE('idat'),
  1730.     quickTimeImageFileMetaDataAtom = FOUR_CHAR_CODE('meta'),
  1731.     quickTimeImageFileColorSyncProfileAtom = FOUR_CHAR_CODE('iicc')
  1732. };
  1733.  
  1734. enum {
  1735.     graphicsImporterDrawsAllPixels = 0,
  1736.     graphicsImporterDoesntDrawAllPixels = 1,
  1737.     graphicsImporterDontKnowIfDrawAllPixels = 2
  1738. };
  1739.  
  1740. /* Flags for GraphicsImportSetFlags */
  1741. enum {
  1742.     kGraphicsImporterDontDoGammaCorrection = 1L
  1743. };
  1744.  
  1745. enum {
  1746.     kGraphicsExportGroup        = FOUR_CHAR_CODE('expo'),
  1747.     kGraphicsExportFileType        = FOUR_CHAR_CODE('ftyp'),
  1748.     kGraphicsExportMIMEType        = FOUR_CHAR_CODE('mime'),
  1749.     kGraphicsExportExtension    = FOUR_CHAR_CODE('ext '),
  1750.     kGraphicsExportDescription    = FOUR_CHAR_CODE('desc')
  1751. };
  1752.  
  1753.  
  1754. /** These are GraphicsImport procedures **/
  1755. EXTERN_API( ComponentResult )
  1756. GraphicsImportSetDataReference    (GraphicsImportComponent  ci,
  1757.                                  Handle                 dataRef,
  1758.                                  OSType                 dataReType)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0001, 0x7000, 0xA82A);
  1759.  
  1760. EXTERN_API( ComponentResult )
  1761. GraphicsImportGetDataReference    (GraphicsImportComponent  ci,
  1762.                                  Handle *                dataRef,
  1763.                                  OSType *                dataReType)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0002, 0x7000, 0xA82A);
  1764.  
  1765. EXTERN_API( ComponentResult )
  1766. GraphicsImportSetDataFile        (GraphicsImportComponent  ci,
  1767.                                  const FSSpec *            theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0003, 0x7000, 0xA82A);
  1768.  
  1769. EXTERN_API( ComponentResult )
  1770. GraphicsImportGetDataFile        (GraphicsImportComponent  ci,
  1771.                                  FSSpec *                theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0004, 0x7000, 0xA82A);
  1772.  
  1773. EXTERN_API( ComponentResult )
  1774. GraphicsImportSetDataHandle        (GraphicsImportComponent  ci,
  1775.                                  Handle                 h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0005, 0x7000, 0xA82A);
  1776.  
  1777. EXTERN_API( ComponentResult )
  1778. GraphicsImportGetDataHandle        (GraphicsImportComponent  ci,
  1779.                                  Handle *                h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0006, 0x7000, 0xA82A);
  1780.  
  1781. EXTERN_API( ComponentResult )
  1782. GraphicsImportGetImageDescription (GraphicsImportComponent  ci,
  1783.                                  ImageDescriptionHandle * desc)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0007, 0x7000, 0xA82A);
  1784.  
  1785. EXTERN_API( ComponentResult )
  1786. GraphicsImportGetDataOffsetAndSize (GraphicsImportComponent  ci,
  1787.                                  unsigned long *        offset,
  1788.                                  unsigned long *        size)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0008, 0x7000, 0xA82A);
  1789.  
  1790. EXTERN_API( ComponentResult )
  1791. GraphicsImportReadData            (GraphicsImportComponent  ci,
  1792.                                  void *                    dataPtr,
  1793.                                  unsigned long             dataOffset,
  1794.                                  unsigned long             dataSize)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x0009, 0x7000, 0xA82A);
  1795.  
  1796. EXTERN_API( ComponentResult )
  1797. GraphicsImportSetClip            (GraphicsImportComponent  ci,
  1798.                                  RgnHandle                 clipRgn)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000A, 0x7000, 0xA82A);
  1799.  
  1800. EXTERN_API( ComponentResult )
  1801. GraphicsImportGetClip            (GraphicsImportComponent  ci,
  1802.                                  RgnHandle *            clipRgn)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000B, 0x7000, 0xA82A);
  1803.  
  1804. EXTERN_API( ComponentResult )
  1805. GraphicsImportSetSourceRect        (GraphicsImportComponent  ci,
  1806.                                  const Rect *            sourceRect)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000C, 0x7000, 0xA82A);
  1807.  
  1808. EXTERN_API( ComponentResult )
  1809. GraphicsImportGetSourceRect        (GraphicsImportComponent  ci,
  1810.                                  Rect *                    sourceRect)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000D, 0x7000, 0xA82A);
  1811.  
  1812. EXTERN_API( ComponentResult )
  1813. GraphicsImportGetNaturalBounds    (GraphicsImportComponent  ci,
  1814.                                  Rect *                    naturalBounds)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x000E, 0x7000, 0xA82A);
  1815.  
  1816. EXTERN_API( ComponentResult )
  1817. GraphicsImportDraw                (GraphicsImportComponent  ci)                                FIVEWORDINLINE(0x2F3C, 0x0000, 0x000F, 0x7000, 0xA82A);
  1818.  
  1819. EXTERN_API( ComponentResult )
  1820. GraphicsImportSetGWorld            (GraphicsImportComponent  ci,
  1821.                                  CGrafPtr                 port,
  1822.                                  GDHandle                 gd)                                    FIVEWORDINLINE(0x2F3C, 0x0008, 0x0010, 0x7000, 0xA82A);
  1823.  
  1824. EXTERN_API( ComponentResult )
  1825. GraphicsImportGetGWorld            (GraphicsImportComponent  ci,
  1826.                                  CGrafPtr *                port,
  1827.                                  GDHandle *                gd)                                    FIVEWORDINLINE(0x2F3C, 0x0008, 0x0011, 0x7000, 0xA82A);
  1828.  
  1829. EXTERN_API( ComponentResult )
  1830. GraphicsImportSetMatrix            (GraphicsImportComponent  ci,
  1831.                                  const MatrixRecord *    matrix)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0012, 0x7000, 0xA82A);
  1832.  
  1833. EXTERN_API( ComponentResult )
  1834. GraphicsImportGetMatrix            (GraphicsImportComponent  ci,
  1835.                                  MatrixRecord *            matrix)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0013, 0x7000, 0xA82A);
  1836.  
  1837. EXTERN_API( ComponentResult )
  1838. GraphicsImportSetBoundsRect        (GraphicsImportComponent  ci,
  1839.                                  const Rect *            bounds)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0014, 0x7000, 0xA82A);
  1840.  
  1841. EXTERN_API( ComponentResult )
  1842. GraphicsImportGetBoundsRect        (GraphicsImportComponent  ci,
  1843.                                  Rect *                    bounds)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0015, 0x7000, 0xA82A);
  1844.  
  1845. EXTERN_API( ComponentResult )
  1846. GraphicsImportSaveAsPicture        (GraphicsImportComponent  ci,
  1847.                                  const FSSpec *            fss,
  1848.                                  ScriptCode             scriptTag)                            FIVEWORDINLINE(0x2F3C, 0x0006, 0x0016, 0x7000, 0xA82A);
  1849.  
  1850. EXTERN_API( ComponentResult )
  1851. GraphicsImportSetGraphicsMode    (GraphicsImportComponent  ci,
  1852.                                  long                     graphicsMode,
  1853.                                  const RGBColor *        opColor)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0017, 0x7000, 0xA82A);
  1854.  
  1855. EXTERN_API( ComponentResult )
  1856. GraphicsImportGetGraphicsMode    (GraphicsImportComponent  ci,
  1857.                                  long *                    graphicsMode,
  1858.                                  RGBColor *                opColor)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0018, 0x7000, 0xA82A);
  1859.  
  1860. EXTERN_API( ComponentResult )
  1861. GraphicsImportSetQuality        (GraphicsImportComponent  ci,
  1862.                                  CodecQ                 quality)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0019, 0x7000, 0xA82A);
  1863.  
  1864. EXTERN_API( ComponentResult )
  1865. GraphicsImportGetQuality        (GraphicsImportComponent  ci,
  1866.                                  CodecQ *                quality)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x001A, 0x7000, 0xA82A);
  1867.  
  1868. EXTERN_API( ComponentResult )
  1869. GraphicsImportSaveAsQuickTimeImageFile (GraphicsImportComponent  ci,
  1870.                                  const FSSpec *            fss,
  1871.                                  ScriptCode             scriptTag)                            FIVEWORDINLINE(0x2F3C, 0x0006, 0x001B, 0x7000, 0xA82A);
  1872.  
  1873. EXTERN_API( ComponentResult )
  1874. GraphicsImportSetDataReferenceOffsetAndLimit (GraphicsImportComponent  ci,
  1875.                                  unsigned long             offset,
  1876.                                  unsigned long             limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x001C, 0x7000, 0xA82A);
  1877.  
  1878. EXTERN_API( ComponentResult )
  1879. GraphicsImportGetDataReferenceOffsetAndLimit (GraphicsImportComponent  ci,
  1880.                                  unsigned long *        offset,
  1881.                                  unsigned long *        limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x001D, 0x7000, 0xA82A);
  1882.  
  1883. EXTERN_API( ComponentResult )
  1884. GraphicsImportGetAliasedDataReference (GraphicsImportComponent  ci,
  1885.                                  Handle *                dataRef,
  1886.                                  OSType *                dataRefType)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x001E, 0x7000, 0xA82A);
  1887.  
  1888. EXTERN_API( ComponentResult )
  1889. GraphicsImportValidate            (GraphicsImportComponent  ci,
  1890.                                  Boolean *                valid)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x001F, 0x7000, 0xA82A);
  1891.  
  1892. EXTERN_API( ComponentResult )
  1893. GraphicsImportGetMetaData        (GraphicsImportComponent  ci,
  1894.                                  void *                    userData)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0020, 0x7000, 0xA82A);
  1895.  
  1896. EXTERN_API( ComponentResult )
  1897. GraphicsImportGetMIMETypeList    (GraphicsImportComponent  ci,
  1898.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0021, 0x7000, 0xA82A);
  1899.  
  1900. EXTERN_API( ComponentResult )
  1901. GraphicsImportDoesDrawAllPixels    (GraphicsImportComponent  ci,
  1902.                                  short *                drawsAllPixels)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0022, 0x7000, 0xA82A);
  1903.  
  1904. EXTERN_API( ComponentResult )
  1905. GraphicsImportGetAsPicture        (GraphicsImportComponent  ci,
  1906.                                  PicHandle *            picture)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0023, 0x7000, 0xA82A);
  1907.  
  1908. EXTERN_API( ComponentResult )
  1909. GraphicsImportExportImageFile    (GraphicsImportComponent  ci,
  1910.                                  OSType                 fileType,
  1911.                                  OSType                 fileCreator,
  1912.                                  const FSSpec *            fss,
  1913.                                  ScriptCode             scriptTag)                            FIVEWORDINLINE(0x2F3C, 0x000E, 0x0024, 0x7000, 0xA82A);
  1914.  
  1915. EXTERN_API( ComponentResult )
  1916. GraphicsImportGetExportImageTypeList (GraphicsImportComponent  ci,
  1917.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0025, 0x7000, 0xA82A);
  1918.  
  1919. EXTERN_API( ComponentResult )
  1920. GraphicsImportDoExportImageFileDialog (GraphicsImportComponent  ci,
  1921.                                  const FSSpec *            inDefaultSpec,
  1922.                                  StringPtr                 prompt,
  1923.                                  ModalFilterYDUPP         filterProc,
  1924.                                  OSType *                outExportedType,
  1925.                                  FSSpec *                outExportedSpec,
  1926.                                  ScriptCode *            outScriptTag)                        FIVEWORDINLINE(0x2F3C, 0x0018, 0x0026, 0x7000, 0xA82A);
  1927.  
  1928. EXTERN_API( ComponentResult )
  1929. GraphicsImportGetExportSettingsAsAtomContainer (GraphicsImportComponent  ci,
  1930.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0027, 0x7000, 0xA82A);
  1931.  
  1932. EXTERN_API( ComponentResult )
  1933. GraphicsImportSetExportSettingsFromAtomContainer (GraphicsImportComponent  ci,
  1934.                                  void *                    qtAtomContainer)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0028, 0x7000, 0xA82A);
  1935.  
  1936. EXTERN_API( ComponentResult )
  1937. GraphicsImportSetProgressProc    (GraphicsImportComponent  ci,
  1938.                                  ICMProgressProcRecordPtr  progressProc)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0029, 0x7000, 0xA82A);
  1939.  
  1940. EXTERN_API( ComponentResult )
  1941. GraphicsImportGetProgressProc    (GraphicsImportComponent  ci,
  1942.                                  ICMProgressProcRecordPtr  progressProc)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x002A, 0x7000, 0xA82A);
  1943.  
  1944. EXTERN_API( ComponentResult )
  1945. GraphicsImportGetImageCount        (GraphicsImportComponent  ci,
  1946.                                  unsigned long *        imageCount)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x002B, 0x7000, 0xA82A);
  1947.  
  1948. EXTERN_API( ComponentResult )
  1949. GraphicsImportSetImageIndex        (GraphicsImportComponent  ci,
  1950.                                  unsigned long             imageIndex)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x002C, 0x7000, 0xA82A);
  1951.  
  1952. EXTERN_API( ComponentResult )
  1953. GraphicsImportGetImageIndex        (GraphicsImportComponent  ci,
  1954.                                  unsigned long *        imageIndex)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x002D, 0x7000, 0xA82A);
  1955.  
  1956. EXTERN_API( ComponentResult )
  1957. GraphicsImportGetDataOffsetAndSize64 (GraphicsImportComponent  ci,
  1958.                                  wide *                    offset,
  1959.                                  wide *                    size)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x002E, 0x7000, 0xA82A);
  1960.  
  1961. EXTERN_API( ComponentResult )
  1962. GraphicsImportReadData64        (GraphicsImportComponent  ci,
  1963.                                  void *                    dataPtr,
  1964.                                  const wide *            dataOffset,
  1965.                                  unsigned long             dataSize)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x002F, 0x7000, 0xA82A);
  1966.  
  1967. EXTERN_API( ComponentResult )
  1968. GraphicsImportSetDataReferenceOffsetAndLimit64 (GraphicsImportComponent  ci,
  1969.                                  const wide *            offset,
  1970.                                  const wide *            limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0030, 0x7000, 0xA82A);
  1971.  
  1972. EXTERN_API( ComponentResult )
  1973. GraphicsImportGetDataReferenceOffsetAndLimit64 (GraphicsImportComponent  ci,
  1974.                                  wide *                    offset,
  1975.                                  wide *                    limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0031, 0x7000, 0xA82A);
  1976.  
  1977. EXTERN_API( ComponentResult )
  1978. GraphicsImportGetDefaultMatrix    (GraphicsImportComponent  ci,
  1979.                                  MatrixRecord *            defaultMatrix)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0032, 0x7000, 0xA82A);
  1980.  
  1981. EXTERN_API( ComponentResult )
  1982. GraphicsImportGetDefaultClip    (GraphicsImportComponent  ci,
  1983.                                  RgnHandle *            defaultRgn)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0033, 0x7000, 0xA82A);
  1984.  
  1985. EXTERN_API( ComponentResult )
  1986. GraphicsImportGetDefaultGraphicsMode (GraphicsImportComponent  ci,
  1987.                                  long *                    defaultGraphicsMode,
  1988.                                  RGBColor *                defaultOpColor)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x0034, 0x7000, 0xA82A);
  1989.  
  1990. EXTERN_API( ComponentResult )
  1991. GraphicsImportGetDefaultSourceRect (GraphicsImportComponent  ci,
  1992.                                  Rect *                    defaultSourceRect)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0035, 0x7000, 0xA82A);
  1993.  
  1994. EXTERN_API( ComponentResult )
  1995. GraphicsImportGetColorSyncProfile (GraphicsImportComponent  ci,
  1996.                                  Handle *                profile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0036, 0x7000, 0xA82A);
  1997.  
  1998. EXTERN_API( ComponentResult )
  1999. GraphicsImportSetDestRect        (GraphicsImportComponent  ci,
  2000.                                  const Rect *            destRect)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0037, 0x7000, 0xA82A);
  2001.  
  2002. EXTERN_API( ComponentResult )
  2003. GraphicsImportGetDestRect        (GraphicsImportComponent  ci,
  2004.                                  Rect *                    destRect)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0038, 0x7000, 0xA82A);
  2005.  
  2006. EXTERN_API( ComponentResult )
  2007. GraphicsImportSetFlags            (GraphicsImportComponent  ci,
  2008.                                  long                     flags)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0039, 0x7000, 0xA82A);
  2009.  
  2010. EXTERN_API( ComponentResult )
  2011. GraphicsImportGetFlags            (GraphicsImportComponent  ci,
  2012.                                  long *                    flags)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x003A, 0x7000, 0xA82A);
  2013.  
  2014.  
  2015.  
  2016.  
  2017. typedef ComponentInstance                 GraphicsExportComponent;
  2018. enum {
  2019.     GraphicsExporterComponentType = FOUR_CHAR_CODE('grex'),
  2020.     kBaseGraphicsExporterSubType = FOUR_CHAR_CODE('base')
  2021. };
  2022.  
  2023. enum {
  2024.     graphicsExporterIsBaseExporter = 1L << 0,
  2025.     graphicsExporterCanTranscode = 1L << 1,
  2026.     graphicsExporterUsesImageCompressor = 1L << 2
  2027. };
  2028.  
  2029.  
  2030. struct QTResolutionSettings {
  2031.     Fixed                             horizontalResolution;
  2032.     Fixed                             verticalResolution;
  2033. };
  2034. typedef struct QTResolutionSettings        QTResolutionSettings;
  2035.  
  2036. struct QTTargetDataSize {
  2037.     unsigned long                     targetDataSize;
  2038. };
  2039. typedef struct QTTargetDataSize            QTTargetDataSize;
  2040. enum {
  2041.     kQTResolutionSettings        = FOUR_CHAR_CODE('reso'),
  2042.     kQTTargetDataSize            = FOUR_CHAR_CODE('dasz'),
  2043.     kQTDontRecompress            = FOUR_CHAR_CODE('dntr'),
  2044.     kQTInterlaceStyle            = FOUR_CHAR_CODE('ilac'),
  2045.     kQTColorSyncProfile            = FOUR_CHAR_CODE('iccp')
  2046. };
  2047.  
  2048. enum {
  2049.     kQTTIFFCompressionMethod    = FOUR_CHAR_CODE('tifc'),        /* UInt32*/
  2050.     kQTTIFFCompression_None        = 1,
  2051.     kQTTIFFCompression_PackBits    = 32773L,
  2052.     kQTTIFFLittleEndian            = FOUR_CHAR_CODE('tife')        /* UInt8 (boolean)*/
  2053. };
  2054.  
  2055. enum {
  2056.     kQTPNGFilterPreference        = FOUR_CHAR_CODE('pngf'),        /* UInt32*/
  2057.     kQTPNGFilterBestForColorType = FOUR_CHAR_CODE('bflt'),
  2058.     kQTPNGFilterNone            = 0,
  2059.     kQTPNGFilterSub                = 1,
  2060.     kQTPNGFilterUp                = 2,
  2061.     kQTPNGFilterAverage            = 3,
  2062.     kQTPNGFilterPaeth            = 4,
  2063.     kQTPNGFilterAdaptivePerRow    = FOUR_CHAR_CODE('aflt'),
  2064.     kQTPNGInterlaceStyle        = FOUR_CHAR_CODE('ilac'),        /* UInt32*/
  2065.     kQTPNGInterlaceNone            = 0,
  2066.     kQTPNGInterlaceAdam7        = 1
  2067. };
  2068.  
  2069.  
  2070. /** These are GraphicsExport procedures **/
  2071. /* To use: set the input and output (and other settings as desired) and call GEDoExport. */
  2072. EXTERN_API( ComponentResult )
  2073. GraphicsExportDoExport            (GraphicsExportComponent  ci,
  2074.                                  unsigned long *        actualSizeWritten)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0001, 0x7000, 0xA82A);
  2075.  
  2076. /* Used for internal communication between the base and format-specific graphics exporter: */
  2077. EXTERN_API( ComponentResult )
  2078. GraphicsExportCanTranscode        (GraphicsExportComponent  ci,
  2079.                                  Boolean *                canTranscode)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0002, 0x7000, 0xA82A);
  2080.  
  2081. EXTERN_API( ComponentResult )
  2082. GraphicsExportDoTranscode        (GraphicsExportComponent  ci)                                FIVEWORDINLINE(0x2F3C, 0x0000, 0x0003, 0x7000, 0xA82A);
  2083.  
  2084. EXTERN_API( ComponentResult )
  2085. GraphicsExportCanUseCompressor    (GraphicsExportComponent  ci,
  2086.                                  Boolean *                canUseCompressor,
  2087.                                  void *                    codecSettingsAtomContainerPtr)        FIVEWORDINLINE(0x2F3C, 0x0008, 0x0004, 0x7000, 0xA82A);
  2088.  
  2089. EXTERN_API( ComponentResult )
  2090. GraphicsExportDoUseCompressor    (GraphicsExportComponent  ci,
  2091.                                  void *                    codecSettingsAtomContainer,
  2092.                                  ImageDescriptionHandle * outDesc)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0005, 0x7000, 0xA82A);
  2093.  
  2094. EXTERN_API( ComponentResult )
  2095. GraphicsExportDoStandaloneExport (GraphicsExportComponent  ci)                                FIVEWORDINLINE(0x2F3C, 0x0000, 0x0006, 0x7000, 0xA82A);
  2096.  
  2097. /* Queries applications can make of a format-specific graphics exporter: */
  2098. EXTERN_API( ComponentResult )
  2099. GraphicsExportGetDefaultFileTypeAndCreator (GraphicsExportComponent  ci,
  2100.                                  OSType *                fileType,
  2101.                                  OSType *                fileCreator)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x0007, 0x7000, 0xA82A);
  2102.  
  2103. EXTERN_API( ComponentResult )
  2104. GraphicsExportGetDefaultFileNameExtension (GraphicsExportComponent  ci,
  2105.                                  OSType *                fileNameExtension)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0008, 0x7000, 0xA82A);
  2106.  
  2107. EXTERN_API( ComponentResult )
  2108. GraphicsExportGetMIMETypeList    (GraphicsExportComponent  ci,
  2109.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0009, 0x7000, 0xA82A);
  2110.  
  2111. /* (1 unused selector) */
  2112. /* Graphics exporter settings: */
  2113. EXTERN_API( ComponentResult )
  2114. GraphicsExportRequestSettings    (GraphicsExportComponent  ci,
  2115.                                  ModalFilterYDUPP         filterProc,
  2116.                                  void *                    yourDataProc)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x000B, 0x7000, 0xA82A);
  2117.  
  2118. EXTERN_API( ComponentResult )
  2119. GraphicsExportSetSettingsFromAtomContainer (GraphicsExportComponent  ci,
  2120.                                  void *                    qtAtomContainer)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x000C, 0x7000, 0xA82A);
  2121.  
  2122. EXTERN_API( ComponentResult )
  2123. GraphicsExportGetSettingsAsAtomContainer (GraphicsExportComponent  ci,
  2124.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x000D, 0x7000, 0xA82A);
  2125.  
  2126. EXTERN_API( ComponentResult )
  2127. GraphicsExportGetSettingsAsText    (GraphicsExportComponent  ci,
  2128.                                  Handle *                theText)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000E, 0x7000, 0xA82A);
  2129.  
  2130. /* Graphics exporters may implement some or none of the following: */
  2131. EXTERN_API( ComponentResult )
  2132. GraphicsExportSetDontRecompress    (GraphicsExportComponent  ci,
  2133.                                  Boolean                 dontRecompress)                        FIVEWORDINLINE(0x2F3C, 0x0002, 0x000F, 0x7000, 0xA82A);
  2134.  
  2135. EXTERN_API( ComponentResult )
  2136. GraphicsExportGetDontRecompress    (GraphicsExportComponent  ci,
  2137.                                  Boolean *                dontRecompress)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0010, 0x7000, 0xA82A);
  2138.  
  2139. EXTERN_API( ComponentResult )
  2140. GraphicsExportSetInterlaceStyle    (GraphicsExportComponent  ci,
  2141.                                  unsigned long             interlaceStyle)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0011, 0x7000, 0xA82A);
  2142.  
  2143. EXTERN_API( ComponentResult )
  2144. GraphicsExportGetInterlaceStyle    (GraphicsExportComponent  ci,
  2145.                                  unsigned long *        interlaceStyle)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0012, 0x7000, 0xA82A);
  2146.  
  2147. EXTERN_API( ComponentResult )
  2148. GraphicsExportSetMetaData        (GraphicsExportComponent  ci,
  2149.                                  void *                    userData)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0013, 0x7000, 0xA82A);
  2150.  
  2151. EXTERN_API( ComponentResult )
  2152. GraphicsExportGetMetaData        (GraphicsExportComponent  ci,
  2153.                                  void *                    userData)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0014, 0x7000, 0xA82A);
  2154.  
  2155. EXTERN_API( ComponentResult )
  2156. GraphicsExportSetTargetDataSize    (GraphicsExportComponent  ci,
  2157.                                  unsigned long             targetDataSize)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0015, 0x7000, 0xA82A);
  2158.  
  2159. EXTERN_API( ComponentResult )
  2160. GraphicsExportGetTargetDataSize    (GraphicsExportComponent  ci,
  2161.                                  unsigned long *        targetDataSize)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0016, 0x7000, 0xA82A);
  2162.  
  2163. EXTERN_API( ComponentResult )
  2164. GraphicsExportSetCompressionMethod (GraphicsExportComponent  ci,
  2165.                                  long                     compressionMethod)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0017, 0x7000, 0xA82A);
  2166.  
  2167. EXTERN_API( ComponentResult )
  2168. GraphicsExportGetCompressionMethod (GraphicsExportComponent  ci,
  2169.                                  long *                    compressionMethod)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0018, 0x7000, 0xA82A);
  2170.  
  2171. EXTERN_API( ComponentResult )
  2172. GraphicsExportSetCompressionQuality (GraphicsExportComponent  ci,
  2173.                                  CodecQ                 spatialQuality)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0019, 0x7000, 0xA82A);
  2174.  
  2175. EXTERN_API( ComponentResult )
  2176. GraphicsExportGetCompressionQuality (GraphicsExportComponent  ci,
  2177.                                  CodecQ *                spatialQuality)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x001A, 0x7000, 0xA82A);
  2178.  
  2179. EXTERN_API( ComponentResult )
  2180. GraphicsExportSetResolution        (GraphicsExportComponent  ci,
  2181.                                  Fixed                     horizontalResolution,
  2182.                                  Fixed                     verticalResolution)                    FIVEWORDINLINE(0x2F3C, 0x0008, 0x001B, 0x7000, 0xA82A);
  2183.  
  2184. EXTERN_API( ComponentResult )
  2185. GraphicsExportGetResolution        (GraphicsExportComponent  ci,
  2186.                                  Fixed *                horizontalResolution,
  2187.                                  Fixed *                verticalResolution)                    FIVEWORDINLINE(0x2F3C, 0x0008, 0x001C, 0x7000, 0xA82A);
  2188.  
  2189. EXTERN_API( ComponentResult )
  2190. GraphicsExportSetDepth            (GraphicsExportComponent  ci,
  2191.                                  long                     depth)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x001D, 0x7000, 0xA82A);
  2192.  
  2193. EXTERN_API( ComponentResult )
  2194. GraphicsExportGetDepth            (GraphicsExportComponent  ci,
  2195.                                  long *                    depth)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x001E, 0x7000, 0xA82A);
  2196.  
  2197. /* (2 unused selectors) */
  2198. EXTERN_API( ComponentResult )
  2199. GraphicsExportSetColorSyncProfile (GraphicsExportComponent  ci,
  2200.                                  Handle                 colorSyncProfile)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0021, 0x7000, 0xA82A);
  2201.  
  2202. EXTERN_API( ComponentResult )
  2203. GraphicsExportGetColorSyncProfile (GraphicsExportComponent  ci,
  2204.                                  Handle *                colorSyncProfile)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0022, 0x7000, 0xA82A);
  2205.  
  2206. /* Always implemented by the base graphics exporter: */
  2207. EXTERN_API( ComponentResult )
  2208. GraphicsExportSetProgressProc    (GraphicsExportComponent  ci,
  2209.                                  ICMProgressProcRecordPtr  progressProc)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0023, 0x7000, 0xA82A);
  2210.  
  2211. EXTERN_API( ComponentResult )
  2212. GraphicsExportGetProgressProc    (GraphicsExportComponent  ci,
  2213.                                  ICMProgressProcRecordPtr  progressProc)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0024, 0x7000, 0xA82A);
  2214.  
  2215. /* Sources for the input image: */
  2216. EXTERN_API( ComponentResult )
  2217. GraphicsExportSetInputDataReference (GraphicsExportComponent  ci,
  2218.                                  Handle                 dataRef,
  2219.                                  OSType                 dataRefType,
  2220.                                  ImageDescriptionHandle  desc)                                FIVEWORDINLINE(0x2F3C, 0x000C, 0x0025, 0x7000, 0xA82A);
  2221.  
  2222. EXTERN_API( ComponentResult )
  2223. GraphicsExportGetInputDataReference (GraphicsExportComponent  ci,
  2224.                                  Handle *                dataRef,
  2225.                                  OSType *                dataRefType)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x0026, 0x7000, 0xA82A);
  2226.  
  2227. EXTERN_API( ComponentResult )
  2228. GraphicsExportSetInputFile        (GraphicsExportComponent  ci,
  2229.                                  const FSSpec *            theFile,
  2230.                                  ImageDescriptionHandle  desc)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0027, 0x7000, 0xA82A);
  2231.  
  2232. EXTERN_API( ComponentResult )
  2233. GraphicsExportGetInputFile        (GraphicsExportComponent  ci,
  2234.                                  FSSpec *                theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0028, 0x7000, 0xA82A);
  2235.  
  2236. EXTERN_API( ComponentResult )
  2237. GraphicsExportSetInputHandle    (GraphicsExportComponent  ci,
  2238.                                  Handle                 h,
  2239.                                  ImageDescriptionHandle  desc)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0029, 0x7000, 0xA82A);
  2240.  
  2241. EXTERN_API( ComponentResult )
  2242. GraphicsExportGetInputHandle    (GraphicsExportComponent  ci,
  2243.                                  Handle *                h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x002A, 0x7000, 0xA82A);
  2244.  
  2245. EXTERN_API( ComponentResult )
  2246. GraphicsExportSetInputPtr        (GraphicsExportComponent  ci,
  2247.                                  Ptr                     p,
  2248.                                  unsigned long             size,
  2249.                                  ImageDescriptionHandle  desc)                                FIVEWORDINLINE(0x2F3C, 0x000C, 0x002B, 0x7000, 0xA82A);
  2250.  
  2251. EXTERN_API( ComponentResult )
  2252. GraphicsExportGetInputPtr        (GraphicsExportComponent  ci,
  2253.                                  Ptr *                    p,
  2254.                                  unsigned long *        size)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x002C, 0x7000, 0xA82A);
  2255.  
  2256. EXTERN_API( ComponentResult )
  2257. GraphicsExportSetInputGraphicsImporter (GraphicsExportComponent  ci,
  2258.                                  GraphicsImportComponent  grip)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x002D, 0x7000, 0xA82A);
  2259.  
  2260. EXTERN_API( ComponentResult )
  2261. GraphicsExportGetInputGraphicsImporter (GraphicsExportComponent  ci,
  2262.                                  GraphicsImportComponent * grip)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x002E, 0x7000, 0xA82A);
  2263.  
  2264. EXTERN_API( ComponentResult )
  2265. GraphicsExportSetInputPicture    (GraphicsExportComponent  ci,
  2266.                                  PicHandle                 picture)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x002F, 0x7000, 0xA82A);
  2267.  
  2268. EXTERN_API( ComponentResult )
  2269. GraphicsExportGetInputPicture    (GraphicsExportComponent  ci,
  2270.                                  PicHandle *            picture)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0030, 0x7000, 0xA82A);
  2271.  
  2272. EXTERN_API( ComponentResult )
  2273. GraphicsExportSetInputGWorld    (GraphicsExportComponent  ci,
  2274.                                  GWorldPtr                 gworld)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0031, 0x7000, 0xA82A);
  2275.  
  2276. EXTERN_API( ComponentResult )
  2277. GraphicsExportGetInputGWorld    (GraphicsExportComponent  ci,
  2278.                                  GWorldPtr *            gworld)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0032, 0x7000, 0xA82A);
  2279.  
  2280. EXTERN_API( ComponentResult )
  2281. GraphicsExportSetInputPixmap    (GraphicsExportComponent  ci,
  2282.                                  PixMapHandle             pixmap)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0033, 0x7000, 0xA82A);
  2283.  
  2284. EXTERN_API( ComponentResult )
  2285. GraphicsExportGetInputPixmap    (GraphicsExportComponent  ci,
  2286.                                  PixMapHandle *            pixmap)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0034, 0x7000, 0xA82A);
  2287.  
  2288. /* Only applicable when the input is a data reference, file, handle or ptr: */
  2289. EXTERN_API( ComponentResult )
  2290. GraphicsExportSetInputOffsetAndLimit (GraphicsExportComponent  ci,
  2291.                                  unsigned long             offset,
  2292.                                  unsigned long             limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0035, 0x7000, 0xA82A);
  2293.  
  2294. EXTERN_API( ComponentResult )
  2295. GraphicsExportGetInputOffsetAndLimit (GraphicsExportComponent  ci,
  2296.                                  unsigned long *        offset,
  2297.                                  unsigned long *        limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0036, 0x7000, 0xA82A);
  2298.  
  2299. /* Used by format-specific graphics exporters when transcoding: */
  2300. EXTERN_API( ComponentResult )
  2301. GraphicsExportMayExporterReadInputData (GraphicsExportComponent  ci,
  2302.                                  Boolean *                mayReadInputData)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0037, 0x7000, 0xA82A);
  2303.  
  2304. EXTERN_API( ComponentResult )
  2305. GraphicsExportGetInputDataSize    (GraphicsExportComponent  ci,
  2306.                                  unsigned long *        size)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0038, 0x7000, 0xA82A);
  2307.  
  2308. EXTERN_API( ComponentResult )
  2309. GraphicsExportReadInputData        (GraphicsExportComponent  ci,
  2310.                                  void *                    dataPtr,
  2311.                                  unsigned long             dataOffset,
  2312.                                  unsigned long             dataSize)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x0039, 0x7000, 0xA82A);
  2313.  
  2314. /* Used by format-specific graphics exporters, especially when doing standalone export: */
  2315. EXTERN_API( ComponentResult )
  2316. GraphicsExportGetInputImageDescription (GraphicsExportComponent  ci,
  2317.                                  ImageDescriptionHandle * desc)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x003A, 0x7000, 0xA82A);
  2318.  
  2319. EXTERN_API( ComponentResult )
  2320. GraphicsExportGetInputImageDimensions (GraphicsExportComponent  ci,
  2321.                                  Rect *                    dimensions)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x003B, 0x7000, 0xA82A);
  2322.  
  2323. EXTERN_API( ComponentResult )
  2324. GraphicsExportGetInputImageDepth (GraphicsExportComponent  ci,
  2325.                                  long *                    inputDepth)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x003C, 0x7000, 0xA82A);
  2326.  
  2327. EXTERN_API( ComponentResult )
  2328. GraphicsExportDrawInputImage    (GraphicsExportComponent  ci,
  2329.                                  CGrafPtr                 gw,
  2330.                                  GDHandle                 gd,
  2331.                                  const Rect *            srcRect,
  2332.                                  const Rect *            dstRect)                            FIVEWORDINLINE(0x2F3C, 0x0010, 0x003D, 0x7000, 0xA82A);
  2333.  
  2334. /* Destinations for the output image: */
  2335. EXTERN_API( ComponentResult )
  2336. GraphicsExportSetOutputDataReference (GraphicsExportComponent  ci,
  2337.                                  Handle                 dataRef,
  2338.                                  OSType                 dataRefType)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x003E, 0x7000, 0xA82A);
  2339.  
  2340. EXTERN_API( ComponentResult )
  2341. GraphicsExportGetOutputDataReference (GraphicsExportComponent  ci,
  2342.                                  Handle *                dataRef,
  2343.                                  OSType *                dataRefType)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x003F, 0x7000, 0xA82A);
  2344.  
  2345. EXTERN_API( ComponentResult )
  2346. GraphicsExportSetOutputFile        (GraphicsExportComponent  ci,
  2347.                                  const FSSpec *            theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0040, 0x7000, 0xA82A);
  2348.  
  2349. EXTERN_API( ComponentResult )
  2350. GraphicsExportGetOutputFile        (GraphicsExportComponent  ci,
  2351.                                  FSSpec *                theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0041, 0x7000, 0xA82A);
  2352.  
  2353. EXTERN_API( ComponentResult )
  2354. GraphicsExportSetOutputHandle    (GraphicsExportComponent  ci,
  2355.                                  Handle                 h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0042, 0x7000, 0xA82A);
  2356.  
  2357. EXTERN_API( ComponentResult )
  2358. GraphicsExportGetOutputHandle    (GraphicsExportComponent  ci,
  2359.                                  Handle *                h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0043, 0x7000, 0xA82A);
  2360.  
  2361. EXTERN_API( ComponentResult )
  2362. GraphicsExportSetOutputOffsetAndMaxSize (GraphicsExportComponent  ci,
  2363.                                  unsigned long             offset,
  2364.                                  unsigned long             maxSize,
  2365.                                  Boolean                 truncateFile)                        FIVEWORDINLINE(0x2F3C, 0x000A, 0x0044, 0x7000, 0xA82A);
  2366.  
  2367. EXTERN_API( ComponentResult )
  2368. GraphicsExportGetOutputOffsetAndMaxSize (GraphicsExportComponent  ci,
  2369.                                  unsigned long *        offset,
  2370.                                  unsigned long *        maxSize,
  2371.                                  Boolean *                truncateFile)                        FIVEWORDINLINE(0x2F3C, 0x000C, 0x0045, 0x7000, 0xA82A);
  2372.  
  2373. EXTERN_API( ComponentResult )
  2374. GraphicsExportSetOutputFileTypeAndCreator (GraphicsExportComponent  ci,
  2375.                                  OSType                 fileType,
  2376.                                  OSType                 fileCreator)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x0046, 0x7000, 0xA82A);
  2377.  
  2378. EXTERN_API( ComponentResult )
  2379. GraphicsExportGetOutputFileTypeAndCreator (GraphicsExportComponent  ci,
  2380.                                  OSType *                fileType,
  2381.                                  OSType *                fileCreator)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x0047, 0x7000, 0xA82A);
  2382.  
  2383. /* Used by format-specific graphics exporters: */
  2384. EXTERN_API( ComponentResult )
  2385. GraphicsExportWriteOutputData    (GraphicsExportComponent  ci,
  2386.                                  const void *            dataPtr,
  2387.                                  unsigned long             dataSize)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0048, 0x7000, 0xA82A);
  2388.  
  2389. EXTERN_API( ComponentResult )
  2390. GraphicsExportSetOutputMark        (GraphicsExportComponent  ci,
  2391.                                  unsigned long             mark)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0049, 0x7000, 0xA82A);
  2392.  
  2393. EXTERN_API( ComponentResult )
  2394. GraphicsExportGetOutputMark        (GraphicsExportComponent  ci,
  2395.                                  unsigned long *        mark)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x004A, 0x7000, 0xA82A);
  2396.  
  2397. EXTERN_API( ComponentResult )
  2398. GraphicsExportReadOutputData    (GraphicsExportComponent  ci,
  2399.                                  void *                    dataPtr,
  2400.                                  unsigned long             dataOffset,
  2401.                                  unsigned long             dataSize)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x004B, 0x7000, 0xA82A);
  2402.  
  2403.  
  2404.  
  2405. typedef ComponentInstance                 ImageTranscoderComponent;
  2406. enum {
  2407.     ImageTranscodererComponentType = FOUR_CHAR_CODE('imtc')
  2408. };
  2409.  
  2410.  
  2411. /** These are ImageTranscoder procedures **/
  2412. EXTERN_API( ComponentResult )
  2413. ImageTranscoderBeginSequence    (ImageTranscoderComponent  itc,
  2414.                                  ImageDescriptionHandle  srcDesc,
  2415.                                  ImageDescriptionHandle * dstDesc,
  2416.                                  void *                    data,
  2417.                                  long                     dataSize)                            FIVEWORDINLINE(0x2F3C, 0x0010, 0x0001, 0x7000, 0xA82A);
  2418.  
  2419. EXTERN_API( ComponentResult )
  2420. ImageTranscoderConvert            (ImageTranscoderComponent  itc,
  2421.                                  void *                    srcData,
  2422.                                  long                     srcDataSize,
  2423.                                  void **                dstData,
  2424.                                  long *                    dstDataSize)                        FIVEWORDINLINE(0x2F3C, 0x0010, 0x0002, 0x7000, 0xA82A);
  2425.  
  2426. EXTERN_API( ComponentResult )
  2427. ImageTranscoderDisposeData        (ImageTranscoderComponent  itc,
  2428.                                  void *                    dstData)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0003, 0x7000, 0xA82A);
  2429.  
  2430. EXTERN_API( ComponentResult )
  2431. ImageTranscoderEndSequence        (ImageTranscoderComponent  itc)                                FIVEWORDINLINE(0x2F3C, 0x0000, 0x0004, 0x7000, 0xA82A);
  2432.  
  2433. /* UPP call backs */
  2434.  
  2435. /* selectors for component calls */
  2436. enum {
  2437.     kGraphicsImportSetDataReferenceSelect            = 0x0001,
  2438.     kGraphicsImportGetDataReferenceSelect            = 0x0002,
  2439.     kGraphicsImportSetDataFileSelect                = 0x0003,
  2440.     kGraphicsImportGetDataFileSelect                = 0x0004,
  2441.     kGraphicsImportSetDataHandleSelect                = 0x0005,
  2442.     kGraphicsImportGetDataHandleSelect                = 0x0006,
  2443.     kGraphicsImportGetImageDescriptionSelect        = 0x0007,
  2444.     kGraphicsImportGetDataOffsetAndSizeSelect        = 0x0008,
  2445.     kGraphicsImportReadDataSelect                    = 0x0009,
  2446.     kGraphicsImportSetClipSelect                    = 0x000A,
  2447.     kGraphicsImportGetClipSelect                    = 0x000B,
  2448.     kGraphicsImportSetSourceRectSelect                = 0x000C,
  2449.     kGraphicsImportGetSourceRectSelect                = 0x000D,
  2450.     kGraphicsImportGetNaturalBoundsSelect            = 0x000E,
  2451.     kGraphicsImportDrawSelect                        = 0x000F,
  2452.     kGraphicsImportSetGWorldSelect                    = 0x0010,
  2453.     kGraphicsImportGetGWorldSelect                    = 0x0011,
  2454.     kGraphicsImportSetMatrixSelect                    = 0x0012,
  2455.     kGraphicsImportGetMatrixSelect                    = 0x0013,
  2456.     kGraphicsImportSetBoundsRectSelect                = 0x0014,
  2457.     kGraphicsImportGetBoundsRectSelect                = 0x0015,
  2458.     kGraphicsImportSaveAsPictureSelect                = 0x0016,
  2459.     kGraphicsImportSetGraphicsModeSelect            = 0x0017,
  2460.     kGraphicsImportGetGraphicsModeSelect            = 0x0018,
  2461.     kGraphicsImportSetQualitySelect                    = 0x0019,
  2462.     kGraphicsImportGetQualitySelect                    = 0x001A,
  2463.     kGraphicsImportSaveAsQuickTimeImageFileSelect    = 0x001B,
  2464.     kGraphicsImportSetDataReferenceOffsetAndLimitSelect = 0x001C,
  2465.     kGraphicsImportGetDataReferenceOffsetAndLimitSelect = 0x001D,
  2466.     kGraphicsImportGetAliasedDataReferenceSelect    = 0x001E,
  2467.     kGraphicsImportValidateSelect                    = 0x001F,
  2468.     kGraphicsImportGetMetaDataSelect                = 0x0020,
  2469.     kGraphicsImportGetMIMETypeListSelect            = 0x0021,
  2470.     kGraphicsImportDoesDrawAllPixelsSelect            = 0x0022,
  2471.     kGraphicsImportGetAsPictureSelect                = 0x0023,
  2472.     kGraphicsImportExportImageFileSelect            = 0x0024,
  2473.     kGraphicsImportGetExportImageTypeListSelect        = 0x0025,
  2474.     kGraphicsImportDoExportImageFileDialogSelect    = 0x0026,
  2475.     kGraphicsImportGetExportSettingsAsAtomContainerSelect = 0x0027,
  2476.     kGraphicsImportSetExportSettingsFromAtomContainerSelect = 0x0028,
  2477.     kGraphicsImportSetProgressProcSelect            = 0x0029,
  2478.     kGraphicsImportGetProgressProcSelect            = 0x002A,
  2479.     kGraphicsImportGetImageCountSelect                = 0x002B,
  2480.     kGraphicsImportSetImageIndexSelect                = 0x002C,
  2481.     kGraphicsImportGetImageIndexSelect                = 0x002D,
  2482.     kGraphicsImportGetDataOffsetAndSize64Select        = 0x002E,
  2483.     kGraphicsImportReadData64Select                    = 0x002F,
  2484.     kGraphicsImportSetDataReferenceOffsetAndLimit64Select = 0x0030,
  2485.     kGraphicsImportGetDataReferenceOffsetAndLimit64Select = 0x0031,
  2486.     kGraphicsImportGetDefaultMatrixSelect            = 0x0032,
  2487.     kGraphicsImportGetDefaultClipSelect                = 0x0033,
  2488.     kGraphicsImportGetDefaultGraphicsModeSelect        = 0x0034,
  2489.     kGraphicsImportGetDefaultSourceRectSelect        = 0x0035,
  2490.     kGraphicsImportGetColorSyncProfileSelect        = 0x0036,
  2491.     kGraphicsImportSetDestRectSelect                = 0x0037,
  2492.     kGraphicsImportGetDestRectSelect                = 0x0038,
  2493.     kGraphicsImportSetFlagsSelect                    = 0x0039,
  2494.     kGraphicsImportGetFlagsSelect                    = 0x003A,
  2495.     kGraphicsExportDoExportSelect                    = 0x0001,
  2496.     kGraphicsExportCanTranscodeSelect                = 0x0002,
  2497.     kGraphicsExportDoTranscodeSelect                = 0x0003,
  2498.     kGraphicsExportCanUseCompressorSelect            = 0x0004,
  2499.     kGraphicsExportDoUseCompressorSelect            = 0x0005,
  2500.     kGraphicsExportDoStandaloneExportSelect            = 0x0006,
  2501.     kGraphicsExportGetDefaultFileTypeAndCreatorSelect = 0x0007,
  2502.     kGraphicsExportGetDefaultFileNameExtensionSelect = 0x0008,
  2503.     kGraphicsExportGetMIMETypeListSelect            = 0x0009,
  2504.     kGraphicsExportRequestSettingsSelect            = 0x000B,
  2505.     kGraphicsExportSetSettingsFromAtomContainerSelect = 0x000C,
  2506.     kGraphicsExportGetSettingsAsAtomContainerSelect = 0x000D,
  2507.     kGraphicsExportGetSettingsAsTextSelect            = 0x000E,
  2508.     kGraphicsExportSetDontRecompressSelect            = 0x000F,
  2509.     kGraphicsExportGetDontRecompressSelect            = 0x0010,
  2510.     kGraphicsExportSetInterlaceStyleSelect            = 0x0011,
  2511.     kGraphicsExportGetInterlaceStyleSelect            = 0x0012,
  2512.     kGraphicsExportSetMetaDataSelect                = 0x0013,
  2513.     kGraphicsExportGetMetaDataSelect                = 0x0014,
  2514.     kGraphicsExportSetTargetDataSizeSelect            = 0x0015,
  2515.     kGraphicsExportGetTargetDataSizeSelect            = 0x0016,
  2516.     kGraphicsExportSetCompressionMethodSelect        = 0x0017,
  2517.     kGraphicsExportGetCompressionMethodSelect        = 0x0018,
  2518.     kGraphicsExportSetCompressionQualitySelect        = 0x0019,
  2519.     kGraphicsExportGetCompressionQualitySelect        = 0x001A,
  2520.     kGraphicsExportSetResolutionSelect                = 0x001B,
  2521.     kGraphicsExportGetResolutionSelect                = 0x001C,
  2522.     kGraphicsExportSetDepthSelect                    = 0x001D,
  2523.     kGraphicsExportGetDepthSelect                    = 0x001E,
  2524.     kGraphicsExportSetColorSyncProfileSelect        = 0x0021,
  2525.     kGraphicsExportGetColorSyncProfileSelect        = 0x0022,
  2526.     kGraphicsExportSetProgressProcSelect            = 0x0023,
  2527.     kGraphicsExportGetProgressProcSelect            = 0x0024,
  2528.     kGraphicsExportSetInputDataReferenceSelect        = 0x0025,
  2529.     kGraphicsExportGetInputDataReferenceSelect        = 0x0026,
  2530.     kGraphicsExportSetInputFileSelect                = 0x0027,
  2531.     kGraphicsExportGetInputFileSelect                = 0x0028,
  2532.     kGraphicsExportSetInputHandleSelect                = 0x0029,
  2533.     kGraphicsExportGetInputHandleSelect                = 0x002A,
  2534.     kGraphicsExportSetInputPtrSelect                = 0x002B,
  2535.     kGraphicsExportGetInputPtrSelect                = 0x002C,
  2536.     kGraphicsExportSetInputGraphicsImporterSelect    = 0x002D,
  2537.     kGraphicsExportGetInputGraphicsImporterSelect    = 0x002E,
  2538.     kGraphicsExportSetInputPictureSelect            = 0x002F,
  2539.     kGraphicsExportGetInputPictureSelect            = 0x0030,
  2540.     kGraphicsExportSetInputGWorldSelect                = 0x0031,
  2541.     kGraphicsExportGetInputGWorldSelect                = 0x0032,
  2542.     kGraphicsExportSetInputPixmapSelect                = 0x0033,
  2543.     kGraphicsExportGetInputPixmapSelect                = 0x0034,
  2544.     kGraphicsExportSetInputOffsetAndLimitSelect        = 0x0035,
  2545.     kGraphicsExportGetInputOffsetAndLimitSelect        = 0x0036,
  2546.     kGraphicsExportMayExporterReadInputDataSelect    = 0x0037,
  2547.     kGraphicsExportGetInputDataSizeSelect            = 0x0038,
  2548.     kGraphicsExportReadInputDataSelect                = 0x0039,
  2549.     kGraphicsExportGetInputImageDescriptionSelect    = 0x003A,
  2550.     kGraphicsExportGetInputImageDimensionsSelect    = 0x003B,
  2551.     kGraphicsExportGetInputImageDepthSelect            = 0x003C,
  2552.     kGraphicsExportDrawInputImageSelect                = 0x003D,
  2553.     kGraphicsExportSetOutputDataReferenceSelect        = 0x003E,
  2554.     kGraphicsExportGetOutputDataReferenceSelect        = 0x003F,
  2555.     kGraphicsExportSetOutputFileSelect                = 0x0040,
  2556.     kGraphicsExportGetOutputFileSelect                = 0x0041,
  2557.     kGraphicsExportSetOutputHandleSelect            = 0x0042,
  2558.     kGraphicsExportGetOutputHandleSelect            = 0x0043,
  2559.     kGraphicsExportSetOutputOffsetAndMaxSizeSelect = 0x0044,
  2560.     kGraphicsExportGetOutputOffsetAndMaxSizeSelect = 0x0045,
  2561.     kGraphicsExportSetOutputFileTypeAndCreatorSelect = 0x0046,
  2562.     kGraphicsExportGetOutputFileTypeAndCreatorSelect = 0x0047,
  2563.     kGraphicsExportWriteOutputDataSelect            = 0x0048,
  2564.     kGraphicsExportSetOutputMarkSelect                = 0x0049,
  2565.     kGraphicsExportGetOutputMarkSelect                = 0x004A,
  2566.     kGraphicsExportReadOutputDataSelect                = 0x004B,
  2567.     kImageTranscoderBeginSequenceSelect                = 0x0001,
  2568.     kImageTranscoderConvertSelect                    = 0x0002,
  2569.     kImageTranscoderDisposeDataSelect                = 0x0003,
  2570.     kImageTranscoderEndSequenceSelect                = 0x0004
  2571. };
  2572.  
  2573. #if PRAGMA_STRUCT_ALIGN
  2574.     #pragma options align=reset
  2575. #elif PRAGMA_STRUCT_PACKPUSH
  2576.     #pragma pack(pop)
  2577. #elif PRAGMA_STRUCT_PACK
  2578.     #pragma pack()
  2579. #endif
  2580.  
  2581. #ifdef PRAGMA_IMPORT_OFF
  2582. #pragma import off
  2583. #elif PRAGMA_IMPORT
  2584. #pragma import reset
  2585. #endif
  2586.  
  2587. #ifdef __cplusplus
  2588. }
  2589. #endif
  2590.  
  2591. #endif /* __IMAGECOMPRESSION__ */
  2592.  
  2593.